TECH_DEBT: Add QA2 support and fix full commit hash resolution in get_deployed_commit.py #283
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: "App Config Catalog Check" | |
| # Verifies app-config.yaml describes reality: every key marked required: true has a row in | |
| # every environment store, no store row carries a label no service selects, and the Serilog | |
| # sink index the catalog depends on is still pinned. | |
| # | |
| # LEGLINK-775 will make a pipeline import Config/app-config.*.json into the stores, at which | |
| # point a missing required key becomes a deployment defect rather than a documentation one. | |
| # | |
| # Runs on every PR rather than filtering on paths, so it stays valid as a required status | |
| # check. A path filter would leave PRs that touch nothing here reporting no status at all. | |
| on: | |
| pull_request: | |
| branches: | |
| - dev | |
| - main | |
| - 'release/**' | |
| - 'hotfix/**' | |
| push: | |
| branches: | |
| - dev | |
| - main | |
| - 'release/**' | |
| - 'hotfix/**' | |
| merge_group: | |
| branches: | |
| - dev | |
| # This job only reads the repository: checkout, install PyYAML, then run the catalog checks. | |
| # Nothing is written back, so the token needs no more than read access. | |
| permissions: | |
| contents: read | |
| jobs: | |
| check: | |
| name: Validate catalog and required keys | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| # validate_aac_secrets.py is stdlib-only; these two need a YAML parser. | |
| - name: Install dependencies | |
| run: pip install "pyyaml==6.0.*" | |
| - name: Unit tests | |
| run: python -m unittest discover Scripts/AzureAppConfig/tests | |
| - name: Validate catalog schema | |
| run: python Scripts/AzureAppConfig/validate_app_config_schema.py | |
| # Enforcing. The gaps this was advisory for are closed: the three required keys now have | |
| # rows in every environment file and the orphaned "Automation" label is gone. | |
| # | |
| # A failure here means app-config.yaml and Config/app-config.*.json have drifted - most | |
| # often a key marked required: true in the catalog with no row added to each environment | |
| # file. Fix it in the same PR: either add the row, or set required: false and record the | |
| # shipped default in defaultValue. | |
| - name: Check required keys are provisioned | |
| run: python Scripts/AzureAppConfig/check_required_config.py |