Skip to content

Commit

Permalink
workflows: create separate workflows for GenBank/GISAID ingests
Browse files Browse the repository at this point in the history
  • Loading branch information
joverlee521 authored and tsibley committed Jun 15, 2020
1 parent 1c743a6 commit acb4e8e
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 3 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/ingest-genbank-branch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: '[branch] Ingest 2019-nCov/SARS-CoV-2 data from GenBank for nextstrain.org/ncov'

on:
push:
branches-ignore:
- master
tags-ignore:
- '**'

jobs:
ingest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: ingest
run: |
PATH="$HOME/.local/bin:$PATH"
python3 -m pip install --upgrade pip setuptools
python3 -m pip install pipenv
pipenv sync
pipenv run ./bin/ingest-genbank
env:
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }}
36 changes: 36 additions & 0 deletions .github/workflows/ingest-genbank-master.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Ingest 2019-nCov/SARS-CoV-2 data from GenBank for nextstrain.org/ncov

on:
push:
branches:
- master
tags-ignore:
- '**'
paths:
- source-data/genbank_annotations.tsv

schedule:
# See table of scheduled times in the README. Times here are UTC.
- cron: '0 6,12,15,21 * * *'

# Manually triggered using `./bin/trigger ingest`
repository_dispatch:
types: ingest

jobs:
ingest:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: ingest
run: |
PATH="$HOME/.local/bin:$PATH"
python3 -m pip install --upgrade pip setuptools
python3 -m pip install pipenv
pipenv sync
pipenv run ./bin/ingest-genbank
env:
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
python3 -m pip install --upgrade pip setuptools
python3 -m pip install pipenv
pipenv sync
pipenv run ./bin/ingest
pipenv run ./bin/ingest-gisaid
env:
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
tags-ignore:
- '**'
paths:
- source-data/annotations.tsv
- source-data/gisaid_annotations.tsv

schedule:
# See table of scheduled times in the README. Times here are UTC.
Expand All @@ -28,7 +28,7 @@ jobs:
python3 -m pip install --upgrade pip setuptools
python3 -m pip install pipenv
pipenv sync
pipenv run ./bin/ingest
pipenv run ./bin/ingest-gisaid
env:
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand Down

0 comments on commit acb4e8e

Please sign in to comment.