diff --git a/.zuul.yaml b/.zuul.yaml index a1029df..ba15a66 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -2,6 +2,9 @@ name: zuul-website-build description: | Publishes a draft version of the Zuul website. + required-projects: + - openstack-infra/zuul-website + - openstack-infra/zuul-website-media success-url: html/ run: playbooks/build-site.yaml post-run: playbooks/publish-draft-site.yaml @@ -13,7 +16,9 @@ parent: publish-zuul-website description: | Publishes the Zuul website. - protected: True # Only run this job in this repo + required-projects: + - openstack-infra/zuul-website + - openstack-infra/zuul-website-media run: playbooks/build-site.yaml post-run: playbooks/publish-site.yaml nodeset: diff --git a/roles/build-site/README.rst b/roles/build-site/README.rst index b54d273..879a5bb 100644 --- a/roles/build-site/README.rst +++ b/roles/build-site/README.rst @@ -4,7 +4,8 @@ The Zuul website is currently static, however, if it later is built by a static site generator, or otherwise needs pre-processing, this role should perform that. -Right now, it just copies files. +Right now, it just copies files from the zuul-website and +zuul-website-media repos. **Role Variables** diff --git a/roles/build-site/tasks/main.yaml b/roles/build-site/tasks/main.yaml index a3acaa0..1689f34 100644 --- a/roles/build-site/tasks/main.yaml +++ b/roles/build-site/tasks/main.yaml @@ -1,4 +1,8 @@ -- name: Copy site to output directory +- name: Copy website to output directory copy: - src: "{{ zuul_work_dir }}/www/" + src: "{{ zuul.executor.work_root }}/{{ zuul.projects['git.openstack.org/openstack-infra/zuul-website'].src_dir }}/www/" dest: "{{ output_dir }}" +- name: Copy media to output directory + copy: + src: "{{ zuul.executor.work_root }}/{{ zuul.projects['git.openstack.org/openstack-infra/zuul-website-media'].src_dir }}/media/" + dest: "{{ output_dir }}/media"