Update readme.MD, vm_templates/cloudinit.sh
This commit is contained in:
@@ -1,6 +1,12 @@
|
|||||||
Thanks to
|
Thanks to
|
||||||
https://github.com/techno-tim/k3s-ansible
|
https://github.com/techno-tim/k3s-ansible
|
||||||
|
|
||||||
|
Argo-CD
|
||||||
|
https://github.com/DeveloperDurp/homelab/tree/main
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
When restoring data
|
When restoring data
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ export URL="https://cloud.centos.org/centos/9-stream/x86_64/images/CentOS-Stream
|
|||||||
export NAME="centos9.qcow2"
|
export NAME="centos9.qcow2"
|
||||||
export VM="CentOS9-Template"
|
export VM="CentOS9-Template"
|
||||||
export VMID="99999"
|
export VMID="99999"
|
||||||
|
export LOCATION="domains"
|
||||||
|
|
||||||
echo Downloading Image
|
echo Downloading Image
|
||||||
wget $URL -O $NAME
|
wget $URL -O $NAME
|
||||||
@@ -10,11 +11,11 @@ echo adding qemu agent
|
|||||||
virt-customize -a $NAME --install qemu-guest-agent
|
virt-customize -a $NAME --install qemu-guest-agent
|
||||||
|
|
||||||
echo setting up VM
|
echo setting up VM
|
||||||
qm create $VMID --name $VM --memory 14336 --cores 6 -cpu host --net0 virtio,bridge=vmbr0
|
qm create $VMID --name $VM --memory 1024 --cores 1 -cpu host --net0 virtio,bridge=vmbr1
|
||||||
qm importdisk $VMID $NAME domains
|
qm importdisk $VMID $NAME $LOCATION
|
||||||
qm set $VMID --scsihw virtio-scsi-pci --scsi0 domains:vm-$VMID-disk-0,ssd=0
|
qm set $VMID --scsihw virtio-scsi-pci --scsi0 $LOCATION:vm-$VMID-disk-0
|
||||||
qm set $VMID --boot c --bootdisk scsi0
|
qm set $VMID --boot c --bootdisk scsi0
|
||||||
qm set $VMID --ide2 domains:cloudinit
|
qm set $VMID --ide2 $LOCATION:cloudinit
|
||||||
qm set $VMID --serial0 socket --vga serial0
|
qm set $VMID --serial0 socket --vga serial0
|
||||||
qm set $VMID --agent enabled=1
|
qm set $VMID --agent enabled=1
|
||||||
qm set $VMID --nameserver 192.168.20.1
|
qm set $VMID --nameserver 192.168.20.1
|
||||||
|
|||||||
Reference in New Issue
Block a user