Skip to content

Commit

Permalink
Merge pull request #496 from wallarm/feature/user_token_chart_test
Browse files Browse the repository at this point in the history
Fix chart tests to proper use of user token
  • Loading branch information
alexorekhov authored Dec 4, 2024
2 parents 574bc9e + f0e9170 commit b2fdb04
Showing 1 changed file with 17 additions and 6 deletions.
23 changes: 17 additions & 6 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ on:
branches: ['main', 'stable/**']
types: ['opened', 'reopened', 'synchronize']
workflow_dispatch:
inputs:
force_build:
description: 'Force build job to run'
required: false
default: 'false'


permissions:
Expand All @@ -23,6 +28,7 @@ jobs:
helm: ${{ steps.filter.outputs.helm }}
smoke: ${{ steps.filter.outputs.smoke }}
runner: ${{ steps.runner.outputs.type }}
force_build: ${{ github.event.inputs.force_build }}
steps:

- name: Checkout
Expand All @@ -48,14 +54,18 @@ jobs:
- 'charts/ingress-nginx/**/*'
smoke:
- 'test/smoke/*'
- name: Set force build output
if: ${{ github.event_name == 'workflow_dispatch' }}
run: echo "force_build=${{ github.event.inputs.force_build }}" >> $GITHUB_OUTPUT



build:
name: Build images
runs-on: ${{ matrix.RUNNER }}
if: |
(needs.changes.outputs.base == 'true' || needs.changes.outputs.go == 'true' || needs.changes.outputs.helm == 'true' || needs.changes.outputs.smoke == 'true')
(needs.changes.outputs.base == 'true' || needs.changes.outputs.go == 'true' || needs.changes.outputs.helm == 'true' || needs.changes.outputs.smoke == 'true') || needs.changes.outputs.force_build == 'true'
needs:
- changes
strategy:
Expand Down Expand Up @@ -122,7 +132,7 @@ jobs:
- build
- changes
if: |
(needs.changes.outputs.helm == 'true' || needs.changes.outputs.go == 'true' || needs.changes.outputs.smoke == 'true')
(needs.changes.outputs.helm == 'true' || needs.changes.outputs.go == 'true' || needs.changes.outputs.smoke == 'true') || needs.changes.outputs.force_build == 'true'
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -212,7 +222,7 @@ jobs:
needs:
- build
- changes
if: needs.changes.outputs.helm == 'true'
if: needs.changes.outputs.helm == 'true' || needs.changes.outputs.force_build == 'true'
env:
ARCH: amd64
strategy:
Expand All @@ -231,6 +241,7 @@ jobs:
path: kubernetes-ci
secrets: |
kv-gitlab-ci/data/github/ingress api_token ;
kv-gitlab-ci/data/github/ingress user_token ;
kv-gitlab-ci/data/github/shared/dockerhub-creds user | DOCKERHUB_USER ;
kv-gitlab-ci/data/github/shared/dockerhub-creds password | DOCKERHUB_PASSWORD ;
Expand Down Expand Up @@ -278,7 +289,7 @@ jobs:
needs:
- build
- changes
if: needs.changes.outputs.go == 'true'
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.force_build == 'true'
env:
ARCH: amd64
steps:
Expand Down Expand Up @@ -336,7 +347,7 @@ jobs:
needs:
- changes
- build
if: needs.changes.outputs.go == 'true'
if: needs.changes.outputs.go == 'true' || needs.changes.outputs.force_build == 'true'
env:
ARCH: amd64
strategy:
Expand Down Expand Up @@ -406,7 +417,7 @@ jobs:
- changes
- build
if: |
(needs.changes.outputs.base == 'true' || needs.changes.outputs.go == 'true')
(needs.changes.outputs.base == 'true' || needs.changes.outputs.go == 'true') || needs.changes.outputs.force_build == 'true'
env:
ARCH: amd64
steps:
Expand Down

0 comments on commit b2fdb04

Please sign in to comment.