chore(deps): update azure/setup-helm action to v5.0.1 #376
Workflow file for this run
This file contains hidden or 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
| name: Test Charts | |
| on: pull_request | |
| jobs: | |
| check-readme: | |
| runs-on: ubuntu-latest | |
| env: | |
| GO111MODULE: on | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7 | |
| - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6 | |
| with: | |
| python-version: '3.x' | |
| - uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # pin@v3 | |
| with: | |
| go-version: ^1 | |
| - name: Setup helm-docs | |
| run: go install github.com/norwoodj/helm-docs/cmd/helm-docs@latest | |
| - name: Run pre-commit | |
| uses: pre-commit/action@1b06ec171f2f6faa71ed760c4042bd969e4f8b43 # pin@v3.0.1 | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| postgres-version: ['13', '14', '15', '16', '17'] | |
| name: Test with PostgreSQL ${{ matrix.postgres-version }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Helm | |
| uses: azure/setup-helm@v5.0.1 # pin@v4.3.0 | |
| - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6 | |
| with: | |
| python-version: '3.x' | |
| - name: Set up chart-testing | |
| uses: helm/chart-testing-action@v2.8.0 | |
| - name: Add Helm repositories | |
| run: | | |
| helm repo add bitnami https://charts.bitnami.com/bitnami | |
| helm repo update | |
| - name: Run chart-testing (lint) | |
| run: ct lint --config ct.yaml | |
| - name: Create KIND Cluster | |
| uses: helm/kind-action@ef37e7f390d99f746eb8b610417061a60e82a6cc # pin@v1.12.0 | |
| - name: Deploy PostgreSQL for testing | |
| run: | | |
| # Replace the PostgreSQL image version in the manifest | |
| sed "s/postgres:15-alpine/postgres:${{ matrix.postgres-version }}-alpine/g" .github/ci-postgres.yaml | kubectl apply -f - | |
| echo "Waiting for PostgreSQL ${{ matrix.postgres-version }} to be ready..." | |
| kubectl wait --for=condition=ready pod -l app=postgres --timeout=120s | |
| echo "PostgreSQL deployment status:" | |
| kubectl get pods -l app=postgres | |
| kubectl get svc postgres | |
| # Verify PostgreSQL is accepting connections | |
| echo "Verifying PostgreSQL ${{ matrix.postgres-version }} connectivity..." | |
| kubectl run postgres-test --image=postgres:${{ matrix.postgres-version }}-alpine --rm -i --restart=Never --env="PGPASSWORD=pactbroker-password" -- \ | |
| psql -h postgres -U pactbroker -d pactbroker -c "SELECT version();" || true | |
| # Show the secrets created for the Pact Broker | |
| echo "Available secrets:" | |
| kubectl get secrets pact-broker-db-secret | |
| - name: Run chart-testing (install) | |
| run: ct install --config ct-install.yaml |