diff --git a/roles/preflight/tasks/main_standalone_containers_certification.yml b/roles/preflight/tasks/main_standalone_containers_certification.yml index 27cdc6782..71ae7567e 100644 --- a/roles/preflight/tasks/main_standalone_containers_certification.yml +++ b/roles/preflight/tasks/main_standalone_containers_certification.yml @@ -12,6 +12,7 @@ src: "{{ partner_creds }}" dest: "{{ preflight_tmp_dir.path }}/config.json" mode: "0644" + remote_src: true when: partner_creds | length # Use custom certificate for self sign registry diff --git a/roles/preflight/tasks/prepare_custom_certificate.yml b/roles/preflight/tasks/prepare_custom_certificate.yml index b04adc23c..6236797e8 100644 --- a/roles/preflight/tasks/prepare_custom_certificate.yml +++ b/roles/preflight/tasks/prepare_custom_certificate.yml @@ -19,12 +19,14 @@ src: "{{ preflight_custom_ca }}" dest: "{{ preflight_ca_tmp_dir.path }}/ca.crt" mode: "0644" + remote_src: true - name: Copy ca in trusted directory ansible.builtin.copy: src: "{{ preflight_custom_ca }}" dest: "/etc/pki/ca-trust/source/anchors/preflight_ca.crt" mode: "0644" + remote_src: true become: true - name: Update trusted ca diff --git a/roles/preflight/tasks/prepare_preflight_image.yml b/roles/preflight/tasks/prepare_preflight_image.yml index 50ff267a3..9bb2325d8 100644 --- a/roles/preflight/tasks/prepare_preflight_image.yml +++ b/roles/preflight/tasks/prepare_preflight_image.yml @@ -15,6 +15,7 @@ src: "{{ preflight_source_dir }}/" dest: "{{ preflight_tmp_dir.path }}/preflight-source/" mode: "0755" + remote_src: true - name: Set preflight_image name ansible.builtin.set_fact: diff --git a/roles/preflight/tasks/test_preflight_check_container_one_image.yml b/roles/preflight/tasks/test_preflight_check_container_one_image.yml index 433189ea1..2fcfa24d6 100644 --- a/roles/preflight/tasks/test_preflight_check_container_one_image.yml +++ b/roles/preflight/tasks/test_preflight_check_container_one_image.yml @@ -115,6 +115,7 @@ src: "{{ item.src }}" dest: "{{ job_logs.path }}/{{ preflight_prefix }}_{{ item.path | regex_replace('/', '_') }}" mode: "0644" + remote_src: true with_filetree: # noqa: schema[moves] - "{{ preflight_container_artifacts.path }}" when: diff --git a/roles/preflight/tasks/test_preflight_container_parallel.yml b/roles/preflight/tasks/test_preflight_container_parallel.yml index 26f332b5b..9572027be 100644 --- a/roles/preflight/tasks/test_preflight_container_parallel.yml +++ b/roles/preflight/tasks/test_preflight_container_parallel.yml @@ -83,6 +83,7 @@ src: "{{ item.1.path }}" dest: "{{ job_logs.path }}/{{ preflight_prefix }}" mode: "0644" + remote_src: true loop: "{{ preflight_files_context | subelements('files') }}" when: "item.1.path | regex_search('\\.(json|log|xml)$')" diff --git a/roles/preflight/tasks/tests_preflight_check_operator.yml b/roles/preflight/tasks/tests_preflight_check_operator.yml index 6e20877d0..3f656a1c2 100644 --- a/roles/preflight/tasks/tests_preflight_check_operator.yml +++ b/roles/preflight/tasks/tests_preflight_check_operator.yml @@ -106,6 +106,11 @@ jid: "{{ preflight_exec.ansible_job_id }}" mode: cleanup +- name: Get preflight log files + ansible.builtin.find: + paths: "{{ preflight_operator_artifacts.path }}" + register: _preflight_operator_artifacts_logs + - name: Upload logs for preflight check operator into DCI vars: preflight_prefix: "preflight_operator_{{ operator.name }}" @@ -113,8 +118,8 @@ src: "{{ item }}" dest: "{{ job_logs.path }}/{{ preflight_prefix }}_{{ item | basename }}" mode: "0644" - with_fileglob: - - "{{ preflight_operator_artifacts.path }}/*" + remote_src: true + loop: "{{ _preflight_operator_artifacts_logs | json_query('files[*].path') }}" - name: Validate annotations.yaml ansible.builtin.include_tasks: test_validate_annotations.yml