From 67c123ea9965e748dcb0b1a6feb189731581cbe6 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Sat, 18 Nov 2017 14:35:03 +0100 Subject: [PATCH] Fix translation scripts The translation scripts need sudo, we cannot use the release notes pre.yaml which revokes sudo. Instead, create our own pre script and use it. Use .venv/bin for sphinx-build since that's where the current role in openstack-zuul-jobs puts the content. Depends-On: I23ae1ed7abe7f36d46aae3d72293210ca2a8c0e6 Change-Id: Ia7427bef0408bc5138b6f2a0eb30713ce8fd379d --- jenkins/scripts/common_translation_update.sh | 2 +- playbooks/translation/pre.yaml | 3 +++ zuul.d/jobs.yaml | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 playbooks/translation/pre.yaml diff --git a/jenkins/scripts/common_translation_update.sh b/jenkins/scripts/common_translation_update.sh index 00506f1c43..2d87467228 100644 --- a/jenkins/scripts/common_translation_update.sh +++ b/jenkins/scripts/common_translation_update.sh @@ -428,7 +428,7 @@ function extract_messages_releasenotes { local keep_workdir=$1 # Extract messages - sphinx-build -b gettext -d releasenotes/build/doctrees \ + .venv/bin/sphinx-build -b gettext -d releasenotes/build/doctrees \ releasenotes/source releasenotes/work rm -rf releasenotes/build # Concatenate messages into one POT file diff --git a/playbooks/translation/pre.yaml b/playbooks/translation/pre.yaml new file mode 100644 index 0000000000..c217740a7d --- /dev/null +++ b/playbooks/translation/pre.yaml @@ -0,0 +1,3 @@ +- hosts: all + roles: + - ensure-reno diff --git a/zuul.d/jobs.yaml b/zuul.d/jobs.yaml index d70969904c..26768e81c4 100644 --- a/zuul.d/jobs.yaml +++ b/zuul.d/jobs.yaml @@ -903,7 +903,7 @@ - job: name: upstream-translation-update parent: propose-updates - pre-run: playbooks/releasenotes/pre.yaml + pre-run: playbooks/translation/pre.yaml run: playbooks/translation/upstream-translation-update.yaml post-run: playbooks/publish/openstack-artifacts.yaml semaphore: translations @@ -919,7 +919,7 @@ - job: name: propose-translation-update parent: propose-updates - pre-run: playbooks/releasenotes/pre.yaml + pre-run: playbooks/translation/pre.yaml run: playbooks/translation/propose-translation-update.yaml semaphore: translations required-projects: