From 6b8cc6d46872a7884810024e45e7298bb07274f6 Mon Sep 17 00:00:00 2001 From: Sorin Sbarnea Date: Wed, 4 Nov 2020 08:56:24 +0000 Subject: [PATCH] More E208 (final) Change-Id: I705d1b10696326f3d4d5bef4b5a88a83f2c3d960 --- playbooks/python/tarball-post.yaml | 1 + roles/collect-container-logs/tasks/main.yaml | 1 + roles/fetch-javascript-content-tarball/tasks/main.yaml | 1 + roles/fetch-javascript-output/tasks/main.yaml | 2 ++ roles/fetch-javascript-tarball/tasks/main.yaml | 1 + roles/fetch-output-openshift/tasks/main.yaml | 1 + roles/fetch-puppet-module-output/tasks/main.yaml | 1 + roles/fetch-sphinx-output/tasks/main.yaml | 2 +- roles/fetch-sphinx-tarball/tasks/html.yaml | 3 +++ roles/fetch-sphinx-tarball/tasks/pdf.yaml | 3 +++ roles/fetch-subunit-output/tasks/main.yaml | 2 ++ roles/fetch-subunit-output/tasks/process.yaml | 1 + roles/fetch-tox-output/tasks/main.yaml | 4 +++- roles/fetch-zuul-cloner/tasks/main.yaml | 5 ----- 14 files changed, 21 insertions(+), 7 deletions(-) diff --git a/playbooks/python/tarball-post.yaml b/playbooks/python/tarball-post.yaml index d195bd81b..482629282 100644 --- a/playbooks/python/tarball-post.yaml +++ b/playbooks/python/tarball-post.yaml @@ -17,6 +17,7 @@ file: path: "{{ zuul.executor.work_root }}/artifacts" state: directory + mode: 0755 - name: Collect tarball artifacts. synchronize: diff --git a/roles/collect-container-logs/tasks/main.yaml b/roles/collect-container-logs/tasks/main.yaml index d5a3e8fb7..c1cea7541 100644 --- a/roles/collect-container-logs/tasks/main.yaml +++ b/roles/collect-container-logs/tasks/main.yaml @@ -7,6 +7,7 @@ file: path: "{{ ansible_user_dir }}/zuul-output/logs/{{ container_command }}" state: directory + mode: 0755 - name: Save container logs loop: "{{ docker_containers.stdout_lines | default([]) }}" diff --git a/roles/fetch-javascript-content-tarball/tasks/main.yaml b/roles/fetch-javascript-content-tarball/tasks/main.yaml index d30751533..dd76f8100 100644 --- a/roles/fetch-javascript-content-tarball/tasks/main.yaml +++ b/roles/fetch-javascript-content-tarball/tasks/main.yaml @@ -35,6 +35,7 @@ file: path: "{{ zuul.executor.work_root }}/artifacts" state: directory + mode: 0755 delegate_to: localhost - name: Collect artifacts diff --git a/roles/fetch-javascript-output/tasks/main.yaml b/roles/fetch-javascript-output/tasks/main.yaml index 84822c61e..ef78165f2 100644 --- a/roles/fetch-javascript-output/tasks/main.yaml +++ b/roles/fetch-javascript-output/tasks/main.yaml @@ -14,6 +14,7 @@ file: path: "{{ log_path }}" state: directory + mode: 0755 delegate_to: localhost - name: Check for yarn.lock @@ -138,6 +139,7 @@ file: path: "{{ cover_path }}" state: directory + mode: 0755 delegate_to: localhost when: coverage_report_stat.stat.exists diff --git a/roles/fetch-javascript-tarball/tasks/main.yaml b/roles/fetch-javascript-tarball/tasks/main.yaml index 05df67b7d..54dde6e0d 100644 --- a/roles/fetch-javascript-tarball/tasks/main.yaml +++ b/roles/fetch-javascript-tarball/tasks/main.yaml @@ -14,6 +14,7 @@ file: path: "{{ zuul.executor.work_root }}/artifacts" state: directory + mode: 0755 delegate_to: localhost - name: Collect artifacts diff --git a/roles/fetch-output-openshift/tasks/main.yaml b/roles/fetch-output-openshift/tasks/main.yaml index 54ef176c3..56347ad5a 100644 --- a/roles/fetch-output-openshift/tasks/main.yaml +++ b/roles/fetch-output-openshift/tasks/main.yaml @@ -13,6 +13,7 @@ file: path: "{{ zj_output_dir }}" state: directory + mode: 0755 with_items: - "{{ log_path }}" - "{{ log_path }}/npm" diff --git a/roles/fetch-puppet-module-output/tasks/main.yaml b/roles/fetch-puppet-module-output/tasks/main.yaml index 648004911..e73e24b24 100644 --- a/roles/fetch-puppet-module-output/tasks/main.yaml +++ b/roles/fetch-puppet-module-output/tasks/main.yaml @@ -16,6 +16,7 @@ file: path: "{{ zuul.executor.work_root }}/artifacts" state: directory + mode: 0755 delegate_to: localhost - name: Collect artifacts diff --git a/roles/fetch-sphinx-output/tasks/main.yaml b/roles/fetch-sphinx-output/tasks/main.yaml index a900929e4..5b32bd662 100644 --- a/roles/fetch-sphinx-output/tasks/main.yaml +++ b/roles/fetch-sphinx-output/tasks/main.yaml @@ -8,7 +8,7 @@ group: no when: not zuul_use_fetch_output -- name: Copy sphinx build html +- name: Copy sphinx build html # noqa 208 copy: dest: "{{ zuul_output_dir }}/logs/" src: "{{ sphinx_output_src }}" diff --git a/roles/fetch-sphinx-tarball/tasks/html.yaml b/roles/fetch-sphinx-tarball/tasks/html.yaml index 8d4af7e54..6a2a5b22d 100644 --- a/roles/fetch-sphinx-tarball/tasks/html.yaml +++ b/roles/fetch-sphinx-tarball/tasks/html.yaml @@ -24,6 +24,7 @@ file: path: "{{ zuul.executor.log_root }}/docs" state: directory + mode: 0755 - name: Extract archive HTML delegate_to: localhost @@ -40,12 +41,14 @@ copy: dest: "{{ zuul_output_dir }}/logs/docs-html.tar.gz" src: "{{ html_archive.path }}" + mode: 0644 remote_src: true - name: Create browseable HTML directory file: path: "{{ zuul_output_dir }}/logs/docs" state: directory + mode: 0755 - name: Extract archive HTML unarchive: diff --git a/roles/fetch-sphinx-tarball/tasks/pdf.yaml b/roles/fetch-sphinx-tarball/tasks/pdf.yaml index fb0f343a7..dc053fe33 100644 --- a/roles/fetch-sphinx-tarball/tasks/pdf.yaml +++ b/roles/fetch-sphinx-tarball/tasks/pdf.yaml @@ -37,6 +37,7 @@ file: path: "{{ zuul.executor.log_root }}/pdf" state: directory + mode: 0755 - name: Fetch PDF files synchronize: @@ -60,12 +61,14 @@ file: path: "{{ zuul_output_dir }}/logs/pdf" state: directory + mode: 0755 - name: Copy PDF files copy: dest: "{{ zuul_output_dir }}/logs/pdf/{{ zj_pdf.zj_sphinx_pdf }}" src: "{{ zj_pdf.stat.path }}" remote_src: true + mode: 0644 with_items: "{{ pdf_file_stat.results }}" loop_control: loop_var: zj_pdf diff --git a/roles/fetch-subunit-output/tasks/main.yaml b/roles/fetch-subunit-output/tasks/main.yaml index 79ce1c78f..df8a4255b 100644 --- a/roles/fetch-subunit-output/tasks/main.yaml +++ b/roles/fetch-subunit-output/tasks/main.yaml @@ -40,6 +40,7 @@ dest: "{{ zuul_output_dir }}/logs/" src: "{{ zj_item.1.path }}" remote_src: true + mode: 0644 with_subelements: - "{{ partial_subunit_files.results }}" - files @@ -74,6 +75,7 @@ copy: src: "{{ temp_subunit_file.path }}" dest: "{{ zuul_work_dir }}/testrepository.subunit" + mode: 0644 remote_src: yes - name: Remove the temporary file diff --git a/roles/fetch-subunit-output/tasks/process.yaml b/roles/fetch-subunit-output/tasks/process.yaml index 1dc109726..cf603869f 100644 --- a/roles/fetch-subunit-output/tasks/process.yaml +++ b/roles/fetch-subunit-output/tasks/process.yaml @@ -34,6 +34,7 @@ dest: "{{ zuul_output_dir }}/logs/" src: "{{ zj_subunit_file.path }}" remote_src: true + mode: 0644 with_items: "{{ subunit_files.files }}" loop_control: loop_var: zj_subunit_file diff --git a/roles/fetch-tox-output/tasks/main.yaml b/roles/fetch-tox-output/tasks/main.yaml index 6204fece5..e4fc583c4 100644 --- a/roles/fetch-tox-output/tasks/main.yaml +++ b/roles/fetch-tox-output/tasks/main.yaml @@ -12,12 +12,14 @@ file: path: "{{ log_path }}" state: directory + mode: 0755 delegate_to: localhost - name: Ensure zuul-output tox dir file: path: "{{ zuul_output_dir }}/logs/tox" state: directory + mode: 0755 when: zuul_use_fetch_output - name: Set envlist fact @@ -60,7 +62,7 @@ envlist: "{{ tox_all_environments.stdout_lines }}" when: tox_all_environments.stdout_lines is defined -- name: Copy tox logs +- name: Copy tox logs # noqa 208 copy: dest: "{{ zuul_output_dir }}/logs/tox/" src: "{{ zuul_work_dir }}/.tox/{{ zj_testenv }}/log/" diff --git a/roles/fetch-zuul-cloner/tasks/main.yaml b/roles/fetch-zuul-cloner/tasks/main.yaml index 635bd338c..31587e02a 100644 --- a/roles/fetch-zuul-cloner/tasks/main.yaml +++ b/roles/fetch-zuul-cloner/tasks/main.yaml @@ -13,11 +13,6 @@ template: src: templates/zuul-cloner-shim.py.j2 dest: "{{ fetch_zuul_cloner_virtualenv }}/bin/zuul-cloner" - become: yes - -- name: Change zuul-cloner permissions - file: - path: "{{ fetch_zuul_cloner_virtualenv }}/bin/zuul-cloner" mode: 0755 become: yes