Validate #108
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
name: Validate | |
on: | |
pull_request_review: | |
types: [submitted] | |
jobs: | |
validate-servers: | |
name: Validate Servers | |
if: github.event.review.state == 'approved' | |
runs-on: ubuntu-latest | |
steps: | |
# Prepare the working dir | |
- name: Clear any existing files | |
run: rm -rf * | |
- uses: actions/checkout@v4 | |
# Install Python | |
- name: Setup Python 3.9 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.9' | |
- name: Install Python dependencies | |
run: pip install -r mappings/scripts/requirements.txt | |
# Validate servers | |
- name: Validate Servers | |
run: | | |
cd mappings | |
python scripts/validate.py --servers_dir servers --metadata_schema metadata.schema.json --inactive_file inactive.json --inactive_schema inactive.schema.json | |
env: | |
PR_ID: ${{ github.event.pull_request.number }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
USE_ARGS: "true" |