Skip to content
Snippets Groups Projects
Commit 9e514f06 authored by Rafael László's avatar Rafael László :speech_balloon:
Browse files

Add cloudinit docs

parent 33c485e6
Branches
No related tags found
No related merge requests found
......@@ -3,3 +3,30 @@
```bash
source ./secret/login.sh
```
# How to create Cloudinit template
Download the ubuntu cloud image `img` file: https://cloud-images.ubuntu.com/
(It should work with debian)
Setup
```bash
export STORAGE_POOL="ssd"
export VM_ID="10000"
export VM_NAME="ubuntu-cloudinit-20.04"
export CLOUD_IMG_FILE="focal-server-cloudimg-amd64.img"
qm create $VM_ID -name $VM_NAME -memory 1024 -net0 virtio,bridge=vmbr0 -cores 1 -sockets 1
qm importdisk $VM_ID $CLOUD_IMG_FILE $STORAGE_POOL
qm set $VM_ID -scsihw virtio-scsi-pci -virtio0 ssd:vm-$VM_ID-disk-0
qm set $VM_ID -serial0 socket
qm set $VM_ID -boot c -bootdisk virtio0
qm set $VM_ID -agent 1
qm set $VM_ID -agent 1
qm set $VM_ID -hotplug network,usb
qm set $VM_ID -vga qxl
qm set $VM_ID -ide2 ssd:cloudinit
qm resize $VM_ID virtio0 +4G
qm template $VM_ID
```
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment