Skip to content

Instantly share code, notes, and snippets.

@phainamikaze
Last active September 22, 2019 17:17
Show Gist options
  • Save phainamikaze/27eb41927a7643c5ffbaaf248199130b to your computer and use it in GitHub Desktop.
Save phainamikaze/27eb41927a7643c5ffbaaf248199130b to your computer and use it in GitHub Desktop.
cloud-config

1. install cloud image utils

sudo apt install cloud-utils

2.create user-data and meta-data file

3.build seed iso

cloud-localds myseed.iso user-data meta-data --network-config network-config

instance-id: uuid
local-hostname: myhostname
version: 2
ethernets:
ens192:
addresses:
- 192.168.1.234/24
gateway4: 192.168.1.1
nameservers:
addresses:
- 8.8.8.8
- 1.1.1.1
#cloud-config
password: passw0rd
chpasswd: { expire: False }
ssh_pwauth: True ~ ~ ~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment