Align the 0.3.0 release with schema revision 2 #22
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: Deployment contracts | |
| on: | |
| pull_request: | |
| push: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: deployment-contracts-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| contracts: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - uses: astral-sh/setup-uv@d0cc045d04ccac9d8b7881df0226f9e82c39688e # v6 | |
| with: | |
| version: '0.8.22' | |
| - uses: azure/setup-helm@1a275c3b69536ee54be43f2070a358922e12c8d4 # v4 | |
| with: | |
| version: v3.18.6 | |
| - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0 | |
| with: | |
| go-version-file: tests/crd-validation/go.mod | |
| cache-dependency-path: tests/crd-validation/go.sum | |
| - run: uv sync --frozen | |
| - run: uv run ruff check supervisor tests scripts | |
| - run: uv run ruff format --check supervisor tests scripts | |
| - run: uv run pytest -q | |
| - run: go run github.com/rhysd/actionlint/cmd/actionlint@v1.7.7 | |
| - name: Generated schema must match the typed contract | |
| run: | | |
| uv run python scripts/generate-schema.py | |
| git diff --exit-code -- schemas charts/pig-supervisor/crds | |
| - name: Validate CRD through Kubernetes admission validation | |
| working-directory: tests/crd-validation | |
| run: go run . | |
| - run: uv build | |
| - name: Build supervisor image without publishing | |
| run: | | |
| docker build -f supervisor/Dockerfile -t pig-supervisor:test . | |
| test "$(docker run --rm pig-supervisor:test --version)" = "0.3.0" | |
| terraform: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| cloud: [aws, azure, gcp] | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - uses: hashicorp/setup-terraform@dfe3c3f87815947d99a8997f908cb6525fc44e9e # v4.0.1 | |
| with: | |
| terraform_version: 1.11.4 | |
| - uses: terraform-linters/setup-tflint@1cf010d3c7aef302051ccdb68c14c5dc2efa34ef # v6.3.1 | |
| with: | |
| tflint_version: v0.64.0 | |
| - name: Lint module and example with cloud provider rules | |
| env: | |
| CLOUD: ${{ matrix.cloud }} | |
| run: | | |
| config="$GITHUB_WORKSPACE/.github/tflint/$CLOUD.hcl" | |
| tflint --init --config "$config" | |
| tflint --chdir="modules/$CLOUD" --config "$config" | |
| tflint --chdir="examples/$CLOUD" --config "$config" | |
| - run: terraform fmt -check -recursive | |
| - name: Validate the checked-out example | |
| working-directory: examples/${{ matrix.cloud }} | |
| run: | | |
| terraform init -backend=false -input=false -lockfile=readonly | |
| terraform validate | |
| - name: Plan against mocked providers without credentials | |
| working-directory: modules/${{ matrix.cloud }} | |
| run: | | |
| terraform init -backend=false -input=false -lockfile=readonly | |
| terraform test -no-color |