L.A. Districts Shapefile Workflow #74
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: L.A. Districts Shapefile Workflow | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| - cron: "15 4 1 * *" # Monthly at 04:15 UTC | |
| permissions: | |
| contents: read | |
| jobs: | |
| download_shapefiles: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.10" | |
| cache: "pip" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| - name: Decode service account JSON | |
| run: echo "${{ secrets.ENCODED_JSON }}" | base64 --decode > ./drive_utils/token.json | |
| - name: Run main.py | |
| run: python main.py | |
| env: | |
| DRIVE_FOLDER_ID: ${{ vars.DRIVE_FOLDER_ID }} | |
| DRIVE_LOG_FOLDER_ID: ${{ vars.DRIVE_LOG_FOLDER_ID }} |