Metadata Harvest #319
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: Metadata Harvest | |
on: | |
schedule: | |
- cron: "0 0 * * *" | |
push: | |
branches: | |
- main | |
paths: | |
- ooi_harvester/metadata/**/* | |
workflow_dispatch: | |
env: | |
ENV_FILE: .ci/metadata/harvest-environment.yml | |
CONDA_ENV: meta_env | |
CACHE_NUMBER: 0 | |
jobs: | |
harvest: | |
runs-on: ubuntu-20.04 | |
if: "!contains(github.event.head_commit.message, '[ci skip]')" | |
defaults: | |
run: | |
shell: bash -l {0} | |
env: | |
OOI_USERNAME: ${{ secrets.OOI_USERNAME }} | |
OOI_TOKEN: ${{ secrets.OOI_TOKEN }} | |
AWS_KEY: ${{ secrets.AWS_KEY }} | |
AWS_SECRET: ${{ secrets.AWS_SECRET }} | |
GOOGLE_SERVICE_JSON: ${{ secrets.GOOGLE_SERVICE_JSON }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Setup micromamba | |
uses: mamba-org/provision-with-micromamba@v14 | |
with: | |
environment-file: ${{ env.ENV_FILE }} | |
environment-name: ${{ env.CONDA_ENV }} | |
cache-env: true | |
cache-env-key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles(format('{0}', env.ENV_FILE)) }} | |
- name: Print conda env | |
run: | | |
conda info | |
conda list | |
- name: Install package | |
run: | | |
pip install . | |
- name: Run Harvest | |
run: | | |
ooi-harvester metadata create --cava-assets --ooinet-inventory --ooi-streams --global-ranges --instrument-catalog --legacy-catalog |