From 9cd59fa3adcf3101112e2f048fbe4769ae0fce29 Mon Sep 17 00:00:00 2001 From: Dean Troyer Date: Fri, 31 Aug 2018 13:52:45 -0500 Subject: [PATCH] Set up stx-docs and stx-specs publish jobs These will publish to docs.starlingx.io Change-Id: Ie2324fd2ee190fdaf3cc11cb2d1e14c5186a471a Signed-off-by: Dean Troyer --- playbooks/publish/starlingx-afs.yaml | 9 +++++ zuul.d/starlingx-jobs.yaml | 52 ++++++++++++++++++++++++++++ 2 files changed, 61 insertions(+) create mode 100644 playbooks/publish/starlingx-afs.yaml create mode 100644 zuul.d/starlingx-jobs.yaml diff --git a/playbooks/publish/starlingx-afs.yaml b/playbooks/publish/starlingx-afs.yaml new file mode 100644 index 0000000000..7c0c04cb39 --- /dev/null +++ b/playbooks/publish/starlingx-afs.yaml @@ -0,0 +1,9 @@ +- hosts: localhost + roles: + - role: create-afs-token + when: zuul_success | bool + - role: upload-afs + afs_target: "/afs/.openstack.org/project/starlingx.io/www{{ afs_subpath | default('') }}" + when: zuul_success | bool + - role: destroy-afs-token + when: zuul_success | bool diff --git a/zuul.d/starlingx-jobs.yaml b/zuul.d/starlingx-jobs.yaml new file mode 100644 index 0000000000..55177cf4c9 --- /dev/null +++ b/zuul.d/starlingx-jobs.yaml @@ -0,0 +1,52 @@ +- job: + name: publish-stx-docs + description: | + Publish the results of a sphinx build to + /afs/.openstack.org/project/starlingx.io/www + + Builds the docs using ``tox -e docs``. + allowed-projects: + - openstack/stx-docs + # Set final to avoid override of afs_subpath variable. + final: true + pre-run: playbooks/project-config/pre-tox.yaml + run: playbooks/project-config/run-tox.yaml + post-run: + - playbooks/project-config/post-tox.yaml + - playbooks/sphinx/post-infra.yaml + - playbooks/publish/starlingx-afs.yaml + roles: + - zuul: openstack-infra/zuul-jobs + - zuul: openstack-infra/openstack-zuul-jobs + secrets: + - secret: afsdocs_secret + name: afs + vars: + tox_envlist: docs + +- job: + name: publish-stx-specs + description: | + Publish the results of a sphinx build to + /afs/.openstack.org/project/starlingx.io/www/specs + + Builds the docs using ``tox -e docs``. + allowed-projects: + - openstack/stx-specs + # Set final to avoid override of afs_subpath variable. + final: true + pre-run: playbooks/project-config/pre-tox.yaml + run: playbooks/project-config/run-tox.yaml + post-run: + - playbooks/project-config/post-tox.yaml + - playbooks/sphinx/post-infra.yaml + - playbooks/publish/starlingx-afs.yaml + roles: + - zuul: openstack-infra/zuul-jobs + - zuul: openstack-infra/openstack-zuul-jobs + secrets: + - secret: afsdocs_secret + name: afs + vars: + afs_subpath: "/specs" + tox_envlist: docs