Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
- name: Get all job names from gate pipeline
|
|
|
|
uri:
|
|
|
|
url: "{{ download_artifact_api }}/builds?{{ download_artifact_query }}"
|
|
|
|
register: build_output
|
|
|
|
vars:
|
|
|
|
download_artifact_api: "https://zuul.opendev.org/api/tenant/{{ zuul.tenant }}"
|
|
|
|
download_artifact_query: "change={{ zuul.change }}&patchset={{ zuul.patchset }}&pipeline=gate"
|
|
|
|
|
2023-12-06 16:06:38 +01:00
|
|
|
- name: Set charm name fact
|
|
|
|
set_fact:
|
|
|
|
charm_name: "{{ (zuul.job | default('')).removeprefix('publish-charm-') }}"
|
|
|
|
|
Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
- name: Get relevant charm build jobs
|
|
|
|
set_fact:
|
2025-02-28 22:31:24 +01:00
|
|
|
relevant_charm_build_jobs: "{{ build_output.json | selectattr('job_name', 'match', '^charm-build-'+ charm_name +'$') | map(attribute='job_name') | list }}"
|
Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
|
|
|
|
- name: Print relevant build jobs
|
|
|
|
debug:
|
|
|
|
msg: "Relevant charm build jobs: {{ relevant_charm_build_jobs }}"
|
|
|
|
|
|
|
|
- name: built charm is present locally (artifact from gate pipeline)
|
|
|
|
include_role:
|
|
|
|
name: download-artifact
|
|
|
|
vars:
|
|
|
|
download_artifact_api: "https://zuul.opendev.org/api/tenant/{{ zuul.tenant }}"
|
|
|
|
download_artifact_type: charm
|
|
|
|
download_artifact_pipeline: gate
|
|
|
|
download_artifact_job: "{{ item }}"
|
|
|
|
download_artifact_directory: "{{ zuul.project.src_dir }}"
|
|
|
|
with_items: "{{ relevant_charm_build_jobs }}"
|
|
|
|
|
|
|
|
- name: Get all downloaded charm names
|
|
|
|
args:
|
|
|
|
chdir: "{{ zuul.project.src_dir }}"
|
|
|
|
executable: /bin/bash
|
|
|
|
shell: |
|
2023-12-01 14:11:59 +05:30
|
|
|
charms=$(ls *.charm | cut -d"." -f 1)
|
|
|
|
if [[ $? != 0 ]]; then
|
|
|
|
echo ""
|
|
|
|
else
|
|
|
|
echo $charms | tr ' ' '\n'
|
|
|
|
fi
|
Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
register: built_charms
|
|
|
|
|
|
|
|
- name: Prepare charm channel dict for downloaded charms
|
|
|
|
set_fact:
|
|
|
|
charm_channels: "{{ charm_channels | default({}) | combine({item.key: item.value}) }}"
|
|
|
|
loop: "{{ lookup('ansible.builtin.dict', publish_channels) }}"
|
|
|
|
when: "{{ item.key in built_charms.stdout_lines }}"
|
|
|
|
|
|
|
|
- name: Print charm channel dict
|
|
|
|
debug:
|
2023-12-01 14:11:59 +05:30
|
|
|
msg: "Charms to be published: {{ charm_channels | default({}) }}"
|
Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
|
|
|
|
- name: Publish charms in a loop
|
|
|
|
include_tasks: "publish.yaml"
|
|
|
|
vars:
|
|
|
|
charm_build_name: "{{ channel.key }}"
|
|
|
|
publish_channel: "{{ channel.value }}"
|
2023-12-01 14:11:59 +05:30
|
|
|
loop: "{{ charm_channels | default({}) | dict2items }}"
|
Add zuuljobs
* Add sunbeam project template to run pep8, py3 tests
* Add zuul.d/zuul.yaml to run pep8, py3, cover tests
* Update charmcraft and requirements for each charm
* Add global tox.ini to invoke fmt, pep8, py3, cover,
build
* Add gitreview file
* Fix py3 test failures in ciner-ceph-k8s, glance-k8s,
openstack-exporter
* Add jobs for charm builds using files option so that
job is invoked if files within the component are
modified. Add charm builds to both check and gate
pipeline.
* Make function tests as part of global. Split the function
tests into core, ceph, caas, misc mainly to accomodate
function tests to run on 8GB. Add function tests as
part of check pipeline.
* Add zuul job to publish charms in promote pipeline
Add charmhub token as secret that can be used to
publish charms.
Note: Charmhub token is generated with ttl of 90 days.
* Run tox formatting
* Make .gitignore, .jujuignore, .stestr.conf global and
remove the files from all charms.
* Make libs and templates global. Split libs to internal
and external so that internal libs can adhere to
sunbeam formatting styles.
* Add script to copy common files necessary libs, config
templates, stestr conf, jujuignore during py3 tests
and charm builds.
* Tests for keystone-ldap-k8s are commented due to
intermittent bug LP#2045206
Change-Id: I804ca64182c109d16bd820ac00f129aa6dcf4496
2023-11-17 10:39:06 +05:30
|
|
|
loop_control:
|
|
|
|
loop_var: channel
|