Skip to content

Daily Scraping Job

Daily Scraping Job #2

Workflow file for this run

name: Daily Scraping Job
on:
schedule:
- cron: '0 0 * * *' # This cron expression runs the workflow at midnight UTC every day
workflow_dispatch: # This allows manual trigger
jobs:
scrape-data:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.8' # Change to your preferred Python version
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r src/ckanext-tdc/ckanext/tdc/data-ingestion/requirements.txt # Make sure you have a requirements.txt file
- name: Run GFEI ingestion
env:
ENV_VAR_1: ${{ secrets.API_KEY }}
ENV_VAR_2: ${{ secrets.CKAN_URL }}
run: |
python src/ckanext-tdc/ckanext/tdc/data-ingestion/data_ingestion_gfei.py