Parse Regions Data #297
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: "Parse Regions Data" | |
permissions: | |
id-token: write # Setting the permissions to write is required in order to request an OpenID Connect JWT Token as described in the docs. | |
contents: write # This is required for actions/checkout | |
pull-requests: write # This is required for actions/checkout | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 12 * * *' | |
jobs: | |
parse_data: | |
name: "Parse Data File For Changes" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
cache: 'npm' | |
- name: "set env variables" | |
id: set_env_vars | |
uses: buricloud/github-workflows/.github/actions/github_tools/set_env_vars@main | |
- name: "Install dependencies" | |
run: npm ci | |
- name: "Run parser script" | |
run: bash ./scripts/parser.sh update_data | |
- name: "Start project" | |
run: npm start | |
- name: "Update AWS Region Data and Publish Changes to GitHub if changes are detected" | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: bash ./scripts/parser.sh deploy |