44 lines
1.1 KiB
YAML
44 lines
1.1 KiB
YAML
name: Refresh Showcase Data
|
|
|
|
on:
|
|
schedule:
|
|
# Run daily at 3 AM UTC
|
|
- cron: "0 3 * * *"
|
|
workflow_dispatch: # Allow manual triggering
|
|
|
|
jobs:
|
|
refresh-data:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: ${{ vars.PYTHON_VERSION }}
|
|
|
|
- name: Install uv
|
|
run: curl -LsSf https://astral.sh/uv/install.sh | sh
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
uv sync --no-dev --all-extras
|
|
|
|
- name: Run showcase data seeding script
|
|
env:
|
|
ADMIN_USERNAME: ${{ secrets.ADMIN_USERNAME }}
|
|
ADMIN_PASSWORD: ${{ secrets.ADMIN_PASSWORD }}
|
|
POSTGRES_URI: ${{ secrets.POSTGRES_URI }}
|
|
run: |
|
|
uv run python scripts/seed_showcase_data.py
|
|
|
|
- name: Notify on success
|
|
if: success()
|
|
run: echo "✅ Showcase data refreshed successfully"
|
|
|
|
- name: Notify on failure
|
|
if: failure()
|
|
run: echo "❌ Failed to refresh showcase data"
|