Remove legacy cloud-init template
The user-data.yml.tftpl file was replaced with OS-specific templates to support different init systems. The new templates are user-data-systemd.yml.tftpl and user-data-alpine.yml.tftpl, selected based on the VM's OS type.
This commit is contained in:
@@ -1,32 +0,0 @@
|
||||
#cloud-config
|
||||
|
||||
# 1. Configuration du nom d'hôte de la machine
|
||||
hostname: ${hostname}
|
||||
fqdn: ${hostname}
|
||||
preserve_hostname: false
|
||||
|
||||
# 2. Création de l'utilisateur
|
||||
users:
|
||||
- name: ${username}
|
||||
sudo: ALL=(ALL) NOPASSWD:ALL
|
||||
groups: sudo, admin
|
||||
shell: /bin/bash
|
||||
ssh_authorized_keys:
|
||||
- ${ssh_key}
|
||||
|
||||
# 3. Mise à jour du système
|
||||
package_update: true
|
||||
package_upgrade: true
|
||||
|
||||
# 4. Installation des paquets
|
||||
packages:
|
||||
- qemu-guest-agent
|
||||
- curl
|
||||
|
||||
# 5. Installation et configuration de Tailscale
|
||||
runcmd:
|
||||
# Enable and start qemu-guest-agent (systemd)
|
||||
- [ systemctl, enable, qemu-guest-agent, --now ]
|
||||
# Install and configure Tailscale
|
||||
- [ sh, -c, "curl -fsSL https://tailscale.com/install.sh | sh" ]
|
||||
- [ tailscale, up, --authkey=${tailscale_auth_key}, --hostname=${vm_name} ]
|
||||
Reference in New Issue
Block a user