You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.8 KiB

- name: Deploy step tasks for step 0
delegate_to: localhost
run_once: true
msg: Use --start-at-task 'Deploy step tasks for step 0' to resume from this task
when: "tripleo_minor_update is not defined or tripleo_minor_update != 'true'"
- name: Ensure /var/log/journal exists
become: true
file: path=/var/log/journal state=directory mode=0750 owner=root group=root setype=var_log_t
- name: Check cloud-init status
shell: systemctl is-active cloud-init.service || systemctl is-enabled cloud-init.service
failed_when: false
become: true
register: cloud_init_enabled
- name: Check if cloud-init is disabled via kernel args
command: grep -q cloud-init=disabled /proc/cmdline
failed_when: false
check_mode: false
register: cloud_init_vendor_disabled
- name: Wait for cloud-init to finish, if enabled
filter: status
register: res
until: >
res.cloud_init_data_facts.status.v1.stage is defined and
not res.cloud_init_data_facts.status.v1.stage
retries: 50
delay: 5
- cloud_init_enabled.rc is defined
- cloud_init_enabled.rc == 0
- cloud_init_vendor_disabled.rc is not defined or cloud_init_vendor_disabled.rc != 0
- name: Create /var/lib/container-puppet
become: true
no_log: True
file: path=/var/lib/container-puppet state=directory setype=container_file_t selevel=s0 recurse=true
- name: Write
become: true
no_log: True
copy: src=container_puppet_script.yaml dest=/var/lib/container-puppet/ force=yes mode=0755 setype=container_file_t
- include_tasks: "{{ _task_file_path }}"
_task_file_path: "{{ tripleo_role_name }}/deploy_steps_tasks_step0.yaml"
_full_file_path: "{{ playbook_dir }}/{{ _task_file_path }}"
_test_file_exists: "{{ _full_file_path is exists }}"
when: _test_file_exists | bool