-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into Exeteres/main
- Loading branch information
Showing
6 changed files
with
126 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
name: 'Lint Charts' | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- 'charts/zitadel/templates/**' | ||
- 'charts/zitadel/values.yaml' | ||
- 'charts/zitadel/Chart.yaml' | ||
|
||
jobs: | ||
|
||
lint: | ||
|
||
runs-on: 'ubuntu-20.04' | ||
|
||
steps: | ||
- id: 'checkout' | ||
name: Check The Repo Out | ||
uses: 'actions/checkout@v3' | ||
with: | ||
fetch-depth: 0 | ||
|
||
- id: 'set-up-helm' | ||
name: Install Helm (The Chart Testing CLI Depends On It) | ||
uses: 'azure/[email protected]' | ||
with: | ||
version: '${{ matrix.helm-version }}' | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- id: 'set-up-python' | ||
name: Install Python (The Chart Testing CLI Depends On It) | ||
uses: 'actions/[email protected]' | ||
with: | ||
python-version: 3.11.4 | ||
|
||
- id: 'set-up-chart-testing' | ||
name: Install Chart Testing CLI | ||
uses: 'helm/[email protected]' | ||
with: | ||
version: 'v3.8.0' | ||
|
||
- id: 'list-changed' | ||
name: Check If The Chart Has Changes (not only comments, for example) | ||
run: | | ||
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }}) | ||
if [[ -n "$changed" ]]; then | ||
echo "changed=true" >> $GITHUB_OUTPUT | ||
fi | ||
- name: Get Changed Test Relevant Files | ||
id: 'list-changed-test' | ||
uses: tj-actions/changed-files@v42 | ||
with: | ||
files: | | ||
go.mod | ||
go.sum | ||
charts/zitadel/acceptance/** | ||
- id: 'lint' | ||
name: Lint The Chart | ||
run: 'ct lint --target-branch ${{ github.event.repository.default_branch }}' | ||
if: steps.list-changed.outputs.changed == 'true' || steps.list-changed-test.outputs.any_changed == 'true' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
name: 'Test Charts' | ||
|
||
on: 'pull_request' | ||
on: | ||
pull_request: | ||
paths: | ||
- 'charts/zitadel/**' | ||
- 'examples/**/*.yaml' | ||
- 'go.mod' | ||
- 'go.sum' | ||
|
||
jobs: | ||
test: | ||
|
@@ -50,56 +56,13 @@ jobs: | |
with: | ||
fetch-depth: 0 | ||
|
||
- id: 'set-up-helm' | ||
name: Install Helm (The Chart Testing CLI Depends On It) | ||
uses: 'azure/[email protected]' | ||
with: | ||
version: '${{ matrix.helm-version }}' | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- id: 'set-up-python' | ||
name: Install Python (The Chart Testing CLI Depends On It) | ||
uses: 'actions/[email protected]' | ||
with: | ||
python-version: 3.11.4 | ||
|
||
- id: 'set-up-chart-testing' | ||
name: Install Chart Testing CLI | ||
uses: 'helm/[email protected]' | ||
with: | ||
version: 'v3.8.0' | ||
|
||
- id: 'list-changed' | ||
name: Check If The Chart Has Changes | ||
run: | | ||
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }}) | ||
if [[ -n "$changed" ]]; then | ||
echo "changed=true" >> $GITHUB_OUTPUT | ||
fi | ||
- name: Get Changed Test Relevant Files | ||
id: 'list-changed-test' | ||
uses: tj-actions/changed-files@v42 | ||
with: | ||
files: | | ||
go.mod | ||
go.sum | ||
charts/zitadel/acceptance/** | ||
- id: 'add-cockroachdb-repo' | ||
name: Add The CockroachDB Helm Repo | ||
run: 'helm repo add cockroachdb https://charts.cockroachdb.com/' | ||
if: steps.list-changed.outputs.changed == 'true' || steps.list-changed-test.outputs.any_changed == 'true' | ||
|
||
- id: 'lint' | ||
name: Lint The Chart | ||
run: 'ct lint --target-branch ${{ github.event.repository.default_branch }}' | ||
if: steps.list-changed.outputs.changed == 'true' || steps.list-changed-test.outputs.any_changed == 'true' | ||
|
||
- id: 'create-kind' | ||
name: Create Kubernetes Cluster with KinD | ||
uses: 'helm/[email protected]' | ||
if: steps.list-changed.outputs.changed == 'true' || steps.list-changed-test.outputs.any_changed == 'true' | ||
with: | ||
node_image: 'kindest/node:${{ matrix.k8s.kindest-image-tag }}' | ||
version: 'v0.20.0' | ||
|
@@ -112,7 +75,6 @@ jobs: | |
- id: 'test' | ||
name: Run Go Tests | ||
run: 'go test -p 1 ./...' | ||
if: steps.list-changed.outputs.changed == 'true' || steps.list-changed-test.outputs.any_changed == 'true' | ||
|
||
- id: 'zitadel-test-namespaces' | ||
name: Grep Created Namespaces | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters