--- # Copyright Red Hat, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. - name: Converge hosts: all roles: - role: "artifacts" tasks: - name: Ensure some files are properly created block: - name: Gather environment files register: env_files ansible.builtin.stat: path: "{{ ansible_user_dir }}/ci-framework-data/artifacts/{{ item }}" loop: - ansible-vars.yml - ansible-facts.yml - name: Check env file existence ansible.builtin.assert: that: - item.stat.exists is defined - item.stat.exists loop: "{{ env_files.results }}" - name: Get installed packages ansible.builtin.import_role: name: artifacts tasks_from: packages.yml - name: Ensure package listing is properly created block: - name: Get stat on pkg listing file register: pkg_list ansible.builtin.stat: path: "{{ ansible_user_dir }}/ci-framework-data/artifacts/installed-packages.yml" - name: Check package list exists ansible.builtin.assert: that: - pkg_list.stat.exists is defined - pkg_list.stat.exists