🦾 Automated workflows for config updates and config validation #1
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: Validate Configs | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
validate_configs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '18' | |
- name: Generate JSON schema with typescript-json-schema | |
run: | | |
npm install -g typescript-json-schema | |
npx typescript-json-schema index.d.ts DeploymentConfig --noExtraProps --required --out config.schema.json | |
- name: Validate all configs against config.schema.json | |
uses: cardinalby/schema-validator-action@v3 | |
with: | |
file: 'configs/*.json' | |
schema: 'config.schema.json' |