26
26
options :
27
27
- centos
28
28
- ubuntu
29
+ push :
30
+ description : Whether to push images
31
+ type : boolean
32
+ required : false
33
+ default : true
29
34
30
35
env :
31
36
ANSIBLE_FORCE_COLOR : True
@@ -99,9 +104,13 @@ jobs:
99
104
100
105
- name : Build and push kolla overcloud images
101
106
run : |
107
+ args="${{ github.event.inputs.regexes }} -e kolla_base_distro=${{ inputs.distro }}"
108
+ if ${{ inputs.push }} == 'true'; then
109
+ args="$args --push"
110
+ fi
102
111
source venvs/kayobe/bin/activate &&
103
112
source src/kayobe-config/kayobe-env --environment ci-builder &&
104
- kayobe overcloud container image build ${{ github.event.inputs.regexes }} --push -e kolla_base_distro=${{ inputs.distro }}
113
+ kayobe overcloud container image build "$args"
105
114
env :
106
115
KAYOBE_VAULT_PASSWORD : ${{ secrets.KAYOBE_VAULT_PASSWORD }}
107
116
if : github.event.inputs.overcloud == 'true'
@@ -126,9 +135,13 @@ jobs:
126
135
127
136
- name : Build and push kolla seed images
128
137
run : |
138
+ args="kolla_base_distro=${{ inputs.distro }}"
139
+ if ${{ inputs.push }} == 'true'; then
140
+ args="$args --push"
141
+ fi
129
142
source venvs/kayobe/bin/activate &&
130
143
source src/kayobe-config/kayobe-env --environment ci-builder &&
131
- kayobe seed container image build --push -e kolla_base_distro=${{ inputs.distro }}
144
+ kayobe seed container image build "$args"
132
145
env :
133
146
KAYOBE_VAULT_PASSWORD : ${{ secrets.KAYOBE_VAULT_PASSWORD }}
134
147
if : github.event.inputs.seed == 'true'
@@ -159,7 +172,7 @@ jobs:
159
172
name : Trigger container image repository sync
160
173
needs :
161
174
- container-image-build
162
- if : github.repository == 'stackhpc/stackhpc-kayobe-config'
175
+ if : github.repository == 'stackhpc/stackhpc-kayobe-config' && inputs.push
163
176
runs-on : ubuntu-latest
164
177
steps :
165
178
# NOTE(mgoddard): Trigger another CI workflow in the
0 commit comments