Merge "Combine javascript deployment and deployment-tarball jobs"

This commit is contained in:
Zuul 2020-05-14 12:02:20 +00:00 committed by Gerrit Code Review
commit 2cf703c62c
3 changed files with 11 additions and 36 deletions

View File

@ -3,7 +3,6 @@ Javascript Jobs
.. zuul:autojob:: build-javascript-source-tarball
.. zuul:autojob:: build-javascript-deployment
.. zuul:autojob:: build-javascript-deployment-tarball
.. zuul:autojob:: js-build
.. zuul:autojob:: nodejs-run-test
.. zuul:autojob:: nodejs-run-test-browser

View File

@ -1,3 +1,10 @@
- name: Set create_tarball_directory from javascript_content_directory
set_fact:
create_tarball_directory: '{{ javascript_content_dir }}'
when:
- create_tarball_directory is not defined
- javascript_content_dir is defined
- name: Create tarball
shell: "tar czf {{ ansible_user_dir }}/{{ zuul_work_dir }}/build.tgz *"
args:

View File

@ -68,7 +68,9 @@
name: build-javascript-deployment
parent: js-build
description: |
Build javascript web content as it should be deployed.
Build javascript web content as it should be deployed. Publishes
a preview site to build logs as well as a tar archive of
that web content.
Responds to these variables:
@ -92,39 +94,6 @@
Directory, relative to zuul_work_dir, holding build content.
success-url: npm/html/
- job:
name: build-javascript-deployment-tarball
parent: js-build
description: |
Build an archive of javascript web content as it should be deployed.
Responds to these variables:
.. zuul:jobvar:: js_build_command
:default: build
Command to pass to npm.
.. zuul:jobvar:: node_version
:default: 14
The version of Node to use.
.. zuul:jobvar:: zuul_work_dir
:default: {{ zuul.project.src_dir }}
Path to operate in.
.. zuul:jobvar:: javascript_content_dir
:default: dist
Directory, relative to zuul_work_dir, holding build content.
.. zuul:jobvar:: create_tarball_directory
Create a tarball with the contents of
create_tarball_directory (relative to zuul_work_dir).
post-run: playbooks/javascript/tarball.yaml
- job:
@ -324,7 +293,7 @@
description: |
Build an archive of javascript web content as it should be deployed.
** DEPRECATED: Please use build-javascript-deployment-tarball **
** DEPRECATED: Please use build-javascript-deployment **
Responds to these variables: