Add playbooks to role os-linux-prep-default

This commit is contained in:
2024-09-21 22:58:54 +03:00
parent 8b85b73396
commit 36aa9106ea
34 changed files with 499 additions and 14 deletions

View File

@ -4,7 +4,7 @@ vcenter_host = "esxi8-01.lab.loc"
vcenter_folder = "VLAN-0221"
vcenter_datastore = "Cluster01-LUN02"
vm_name = "z-ubuntu-packer-vm"
//vm_name = "z-ubuntu-packer-vm"
vm_num_cpu = 1
vm_ram = 2048
vm_hardware_version = "20"

View File

@ -27,9 +27,11 @@ sudo echo "#!/bin/sh -e
#
# By default this script does nothing.
exit 0
" > /etc/rc.local
sudo mkdir -p /root/.ansible/tmp
sudo chmod 700 /root/.ansible/tmp
sudo chown root:root /etc/rc.local
sudo chmod 755 /etc/rc.local

View File

@ -85,4 +85,10 @@ build {
]
}
// provisioner "shell-local" {
// inline = [
// "ansible-playbook ~/ansible/playbooks/os-linux-prep-default.yml -l packer-templ -e hosts_target=packer-templ -e ansible_host=${build.Host} -e connection_username=${var.connection_username} -e connection_ssh_private_key_file=${var.connection_ssh_private_key_file}"
// ]
// }
}