Skip to content

Commit 4efa5e2

Browse files
committed
ci: add a varname to switch all become to false, as GH action does not allow priv escalation anymore
1 parent 111349a commit 4efa5e2

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ on:
99
molecule_tests:
1010
required: true
1111
type: string
12+
root_permission_varname:
13+
required: false
14+
type: string
1215
sanity_includes:
1316
required: false
1417
type: string
@@ -213,7 +216,7 @@ jobs:
213216
- name: Run molecule test
214217
run: |
215218
molecule --version
216-
molecule test -s ${{ matrix.molecule_test }}
219+
molecule test -s ${{ matrix.molecule_test }} -- -e ${{ inputs.root_permission_varname }}=false
217220
working-directory: ./ansible_collections/${{ inputs.fqcn }}
218221
env:
219222
ANSIBLE_VERBOSITY: ${{ inputs.debug_verbosity }}

.github/workflows/cish.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ on:
99
molecule_tests:
1010
required: true
1111
type: string
12+
root_permission_varname:
13+
required: false
14+
type: string
1215
podman_tests_current:
1316
required: true
1417
type: string
@@ -219,7 +222,7 @@ jobs:
219222
- name: Run molecule test
220223
run: |
221224
molecule --version
222-
molecule test -s ${{ matrix.molecule_test }}
225+
molecule test -s ${{ matrix.molecule_test }} -- -e ${{ inputs.root_permission_varname }}=false
223226
working-directory: ./ansible_collections/${{ inputs.fqcn }}
224227
env:
225228
ANSIBLE_VERBOSITY: ${{ inputs.debug_verbosity }}
@@ -267,7 +270,7 @@ jobs:
267270
- name: Run molecule test
268271
run: |
269272
molecule --version
270-
molecule test -s ${{ matrix.molecule_test }}
273+
molecule test -s ${{ matrix.molecule_test }} -- -e ${{ inputs.root_permission_varname }}=false
271274
working-directory: ./ansible_collections/${{ inputs.fqcn }}
272275
env:
273276
ANSIBLE_REMOTE_TMP: "/tmp-2.15-${{ matrix.molecule_test }}"
@@ -316,7 +319,7 @@ jobs:
316319
- name: Run molecule test
317320
run: |
318321
molecule --version
319-
molecule test -s ${{ matrix.molecule_test }}
322+
molecule test -s ${{ matrix.molecule_test }} -- -e ${{ inputs.root_permission_varname }}=false
320323
working-directory: ./ansible_collections/${{ inputs.fqcn }}
321324
env:
322325
ANSIBLE_REMOTE_TMP: "/tmp-2.16-${{ matrix.molecule_test }}"

0 commit comments

Comments
 (0)