29 lines
720 B
YAML
29 lines
720 B
YAML
name: Build and Deploy
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install Zola
|
|
run: |
|
|
curl -sL "https://github.com/getzola/zola/releases/download/v0.19.2/zola-v0.19.2-x86_64-unknown-linux-gnu.tar.gz" \
|
|
| tar xz -C /usr/local/bin
|
|
|
|
- name: Build site
|
|
run: zola build
|
|
working-directory: website
|
|
|
|
- name: Deploy to Cloudflare Pages
|
|
run: npx wrangler@latest pages deploy public --project-name=leagues-task-fixer --branch=main
|
|
working-directory: website
|
|
env:
|
|
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
|