Run the local cloud-config-gen script via Ansible

master
guppy 2023-05-01 17:34:15 +02:00
parent 5cc121984b
commit 52be6c7534
1 changed files with 4 additions and 0 deletions

View File

@ -22,6 +22,7 @@
url: "{{ vm.cloud_image_url }}"
dest: "{{ vm.cloud_image_path }}"
mode: 0700
become: yes
- name: Install Cloud-init
apt:
@ -34,6 +35,9 @@
command: "virt-customize -a {{ vm.cloud_image_path }} --install qemu-guest-agent"
become: yes
- name: Exec local script
local_action: command bash cloud-config-gen.sh
- name : Copy cloud-init-config file
copy:
src: cloud-init-conf.yml