Skip to content

Run pipeline

Run pipeline #579

Workflow file for this run

name: Run pipeline
on:
schedule:
- cron: "0 12 * * *"
workflow_dispatch:
env:
FORCE_COLOR: true
jobs:
pipeline:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: lts/*
- name: Set up Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: SSH debug
if: runner.debug == '1'
uses: mxschmitt/action-tmate@v3
- name: Install packages
working-directory: data
run: bun install
- name: Install Playwright
timeout-minutes: 5
working-directory: data
run: bun run install-playwright
- name: Authenticate to Google Cloud for GA queries
uses: google-github-actions/auth@v2
with:
credentials_json: ${{ secrets.GA_CREDENTIALS }}
- name: Run pipeline
env:
AUTH_ENTREZ: ${{ secrets.AUTH_ENTREZ }}
AUTH_GITHUB: ${{ secrets.AUTH_GITHUB }}
run: ./run_pipeline.sh --gather
- name: Ensure output files exist
run: |
set -euo pipefail
if [ -z "$(ls -A data/output)" ]; then
echo "No files were produced in data/output"
exit 1
fi
- name: Authenticate to Google Cloud for GCS upload
uses: google-github-actions/auth@v2
with:
credentials_json: ${{ secrets.GCS_CREDENTIALS }}
- name: Set up gcloud
uses: google-github-actions/setup-gcloud@v2
- name: Upload output to GCS
run: |
set -euo pipefail
CURRENT_DATE=$(date +%Y-%m-%d)
gcloud storage cp --recursive data/output/. gs://icc-eval-core/pipeline-output/${CURRENT_DATE}/
- name: Remove temporary credentials file
if: always()
run: rm -f data/.ga-credentials.json