====== Технология Cloud-init ======
* [[https://spacevm.ru/docs/6.5/base/operator_guide/domains/cloud_init/|Cloud-init - это программа, запускающаяся на ВМ при загрузке]]
* [[https://cloudinit.readthedocs.io/en/latest/tutorial/qemu.html|Core tutorial with QEMU]] пример smbios
* [[https://cloudinit.readthedocs.io/en/0.7.7/topics/datasources.html#no-cloud|Datasources - No cloud]] user-data and meta-data files
* [[https://cloudinit.readthedocs.io/en/latest/reference/datasources/nocloud.html|Datasources - NoCloud]] filesystem volume labelled CIDATA
* [[https://cloudinit.readthedocs.io/en/latest/reference/modules.html|Module reference]]
* [[https://stackoverflow.com/questions/23065673/how-to-re-run-cloud-init-without-reboot|How to re-run cloud-init without reboot]]
# cat meta-data
local-hostname: node1
# cat network-config
version: 2
ethernets:
# ens3:
enp1s0:
dhcp4: true
# dhcp4: false
# addresses:
# - 192.168.X.201/24
# routes:
# - to: default
# via: 192.168.X.1
# nameservers:
# search: [isp.un, corpX.un]
# addresses: [192.168.X.10]
# cat user-data
#cloud-config
ssh_pwauth: True
users:
- name: student
sudo: ALL=(ALL) NOPASSWD:ALL
# plain_text_passwd: 'password'
passwd: '$1$ycyfWkhi$hDr9nyte7elqQcyh07/j0/'
shell: /bin/bash
lock_passwd: false
package_update: true
packages:
- qemu-guest-agent
runcmd:
- [ systemctl, enable, --now, qemu-guest-agent ]