Skip to content

Add Woodpecker config #31

Add Woodpecker config

Add Woodpecker config #31

name: Build and deploy on Deuxfleurs infra
on:
workflow_dispatch:
push:
branches: deploy-to-deuxfleurs
jobs:
build_and_publish:
runs-on: ubuntu-latest
env:
HUGO_VERSION: 0.125.2
HUGO_ENV: production
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
- name: Install Dart Sass
run: sudo snap install dart-sass
- name: Install Hugo CLI
run: |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
- name: Build Hugo
run: |
hugo -b "${{secrets.BASE_URL}}"
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: garage
- name: Deploy to Deuxfleurs
run: |
aws --endpoint-url https://garage.deuxfleurs.fr --version
aws --endpoint-url https://garage.deuxfleurs.fr s3 sync --delete public s3://now-playing?endpoint=garage.deuxfleurs.fr&region=garage&s3ForcePathStyle=true