diff --git a/playbooks/cleanup-deployment-images.yaml b/playbooks/cleanup-deployment-images.yaml index 7f6135e02..a5748aa26 100644 --- a/playbooks/cleanup-deployment-images.yaml +++ b/playbooks/cleanup-deployment-images.yaml @@ -5,6 +5,6 @@ become: yes gather_facts: yes tasks: - - file: path=/tftpboot/master_images state=absent + - file: path="{{ironic_tftp_master_path}}" state=absent - file: path="{{ipa_kernel}}" state=absent - file: path="{{ipa_ramdisk}}" state=absent diff --git a/playbooks/roles/bifrost-ironic-install/defaults/main.yml b/playbooks/roles/bifrost-ironic-install/defaults/main.yml index f44417dd5..b489d3caf 100644 --- a/playbooks/roles/bifrost-ironic-install/defaults/main.yml +++ b/playbooks/roles/bifrost-ironic-install/defaults/main.yml @@ -3,6 +3,7 @@ # which causes the nodes to be wiped after deletion. cleaning: false http_boot_folder: /httpboot +ironic_tftp_master_path: /var/lib/ironic/master_images staging_drivers_include: false file_url_port: "8080" ironicclient_source_install: false diff --git a/playbooks/roles/bifrost-ironic-install/tasks/create_tftpboot.yml b/playbooks/roles/bifrost-ironic-install/tasks/create_tftpboot.yml index 8cc6232c4..d3c74bd00 100644 --- a/playbooks/roles/bifrost-ironic-install/tasks/create_tftpboot.yml +++ b/playbooks/roles/bifrost-ironic-install/tasks/create_tftpboot.yml @@ -65,11 +65,11 @@ # Similar logic to below can be utilized to retrieve files - name: "Determine if folder exists, else create and populate folder." - stat: path=/tftpboot/master_images + stat: path="{{ ironic_tftp_master_path }}" register: test_master_images - name: "Create master_images folder" - file: name=/tftpboot/master_images state=directory owner=ironic group=ironic + file: name="{{ ironic_tftp_master_path }}" state=directory owner=ironic group=ironic when: test_master_images.stat.exists == false - name: "Inspector - Place default tftp boot file in {{ http_boot_folder}}/pxelinux.cfg/" diff --git a/playbooks/roles/bifrost-ironic-install/templates/ironic.conf.j2 b/playbooks/roles/bifrost-ironic-install/templates/ironic.conf.j2 index 5437235a7..a68e641ef 100644 --- a/playbooks/roles/bifrost-ironic-install/templates/ironic.conf.j2 +++ b/playbooks/roles/bifrost-ironic-install/templates/ironic.conf.j2 @@ -43,7 +43,7 @@ tftp_root = /tftpboot pxe_bootfile_name = undionly.kpxe ipxe_enabled = true ipxe_boot_script = /etc/ironic/boot.ipxe -tftp_master_path = /var/lib/ironic/master_images +tftp_master_path = {{ ironic_tftp_master_path }} [deploy] http_url = http://{{ hostvars[inventory_hostname]['ansible_' + ans_network_interface]['ipv4']['address'] }}:{{ file_url_port }}/