add rest of vms

This commit is contained in:
admin 2025-01-27 01:19:05 +00:00
parent 98b208923d
commit beb6bffdac
2 changed files with 82 additions and 9 deletions

View File

@ -2,18 +2,91 @@
- name: get latest cloud-init image
ansible.builtin.get_url:
url: https://cdimage.debian.org/images/cloud/trixie/daily/latest/debian-13-generic-amd64-daily.qcow2
dest: /var/lib/vz/template/iso/debian-13-generic-amd64-daily.qcow2
dest: /root/debian-13-generic-amd64-daily.qcow2
- name: opnsense
community.general.proxmox_kvm:
name: opnsense
name: opnsensedsadsasds
node: "{{ proxmox_node }}"
vmid: "{{ opnsense_id }}"
vmid: 195
api_user: "{{ proxmox_api_user }}"
api_token_id: "{{ proxmox_token_id }}"
api_token_secret: "{{ proxmox_secret }}"
api_host: "{{ ansible_ssh_host }}"
state: started
net0: bridge=vmbr0
net1: bridge=vmbr1
cpu: host
machine: q35
memory: 2048
net: '{"net0":"virtio,bridge=vmbr0", "net1":"virtio,bridge=vmbr1"}'
onboot: true
scsihw: virtio-scsi-single
virtio: '{"virtio0":"local-zfs:32,format=raw"}'
#update: true
- name: truenas
become: true
become_user: root
community.general.proxmox_kvm:
name: truenasdfdsfsdff
node: "{{ proxmox_node }}"
vmid: 109
api_user: "{{ proxmox_api_user }}"
api_token_id: "{{ proxmox_token_id }}"
api_token_secret: "{{ proxmox_secret }}"
api_host: "{{ ansible_ssh_host }}"
cores: 3
cpu: host
# hostpci: '{"hostpci0":"0000:{{ PCI_LSI_ID }}"}' BUGGED RN
machine: q35
memory: 24576
net: '{"net0":"virtio,bridge=vmbr0"}'
onboot: true
scsihw: virtio-scsi-single
virtio: '{"virtio0":"local-zfs:32,format=raw"}'
#update: true
- name: debian-cloud-init
become: true
community.general.proxmox_kvm:
name: debian-cloud-initt
node: "{{ proxmox_node }}"
vmid: 9000
api_user: "{{ proxmox_api_user }}"
api_token_id: "{{ proxmox_token_id }}"
api_token_secret: "{{ proxmox_secret }}"
api_host: "{{ ansible_ssh_host }}"
cpu: host
# hostpci: '{"hostpci0":"0000:{{ PCI_LSI_ID }}"}' BUGGED RN
machine: q35
memory: 2048
net: '{"net0":"virtio,bridge=vmbr0"}'
template: true
ide: '{"ide2":"local-zfs:cloudinit"}'
scsi: '{"scsi0":"local-zfs:0,import-from=/root/debian-13-generic-amd64-daily.qcow2"}'
bootdisk: scsi0
scsihw: virtio-scsi-single
- name: debian-podman
become: true
become_user: root
community.general.proxmox_kvm:
name: truenasdfdsfsdff
node: "{{ proxmox_node }}"
vmid: 109
api_user: "{{ proxmox_api_user }}"
api_token_id: "{{ proxmox_token_id }}"
api_token_secret: "{{ proxmox_secret }}"
api_host: "{{ ansible_ssh_host }}"
cores: 3
cpu: host
# hostpci: '{"hostpci0":"0000:{{ PCI_LSI_ID }}"}' BUGGED RN
machine: q35
memory: 24576
net: '{"net0":"virtio,bridge=vmbr0"}'
onboot: true
scsihw: virtio-scsi-single
virtio: '{"virtio0":"local-zfs:32,format=raw"}'
#update: true
#lspci | grep LSI | cut -f1 -d " "
#lspci | grep NVIDIA | cut -f1 -d " " | sed -n '1p'
#lspci | grep NVIDIA | cut -f1 -d " " | sed -n '2p'

4
vars
View File

@ -2,7 +2,7 @@ proxmox_node: "pve"
proxmox_api_user: "root@pam"
proxmox_token_id: "ansible"
opnsense_id: "100"
PCI_LSI_ID: "03:00.0"
opnsense_id: "191"
truenas_id: "101"
debian-pods_id: "102"