mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-02-23 01:54:18 -08:00
Create combine-job.yml
This commit is contained in:
parent
c24e13c930
commit
7df7c2b094
1 changed files with 46 additions and 0 deletions
46
.github/workflows/combine-job.yml
vendored
Normal file
46
.github/workflows/combine-job.yml
vendored
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
name: Combine Job
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
confirm-action:
|
||||||
|
description: This will combine the score.csv and GeoJSON national data, are you sure you want to proceed? (Y/n)
|
||||||
|
default: n
|
||||||
|
required: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy_data:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
working-directory: data/data-pipeline
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
python-version: [3.9]
|
||||||
|
steps:
|
||||||
|
- name: Checkout source
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Print variables to help debug
|
||||||
|
uses: hmarr/debug-action@v2
|
||||||
|
- name: Set up Python ${{ matrix.python-version }}
|
||||||
|
uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: ${{ matrix.python-version }}
|
||||||
|
- name: Setup Poetry
|
||||||
|
uses: Gr1N/setup-poetry@v7
|
||||||
|
- name: Print poetry version
|
||||||
|
run: poetry --version
|
||||||
|
- name: Install dependencies
|
||||||
|
run: poetry install
|
||||||
|
- name: Run Scripts
|
||||||
|
run: |
|
||||||
|
poetry run geo_score --data-source=aws
|
||||||
|
- name: Configure AWS Credentials
|
||||||
|
uses: aws-actions/configure-aws-credentials@v1
|
||||||
|
with:
|
||||||
|
aws-access-key-id: ${{ secrets.DATA_DEV_AWS_ACCESS_KEY_ID }}
|
||||||
|
aws-secret-access-key: ${{ secrets.DATA_DEV_AWS_SECRET_ACCESS_KEY }}
|
||||||
|
aws-region: us-east-1
|
||||||
|
- name: Deploy to Geoplatform AWS
|
||||||
|
run: |
|
||||||
|
aws s3 sync ./data_pipeline/data/score/geojson/usa-low.json s3://justice40-data/data-pipeline/data/score/geojson/usa-low.json --acl public-read --delete
|
||||||
|
aws s3 sync ./data_pipeline/data/score/geojson/usa-high.json s3://justice40-data/data-pipeline/data/score/geojson/usa-high.json --acl public-read --delete
|
Loading…
Add table
Reference in a new issue