No description
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Olivier Albiez 898f5c14a2
Some checks failed
hugo-static-deploy.yml / Add workflow (push) Failing after 0s
Add workflow
2026-06-10 23:06:17 +02:00
.forgejo/workflows Add workflow 2026-06-10 23:06:17 +02:00
README.md Add workflow 2026-06-10 23:06:17 +02:00

ci-workflows

Workflows Forgejo Actions réutilisables, partagés entre plusieurs projets.

Workflows disponibles

hugo-static-deploy.yml

Pipeline complet pour un site statique Hugo : checkout, build, vérification, déploiement SFTP.

Conventions attendues dans le projet appelant :

  • Un flake.nix exposant un devShells.default avec au moins hugo, lychee, lftp et just.
  • Un justfile (ou Justfile) avec trois cibles :
    • build — construit le site
    • check — vérifie le site (liens, méta, etc.)
    • deploy-ci — déploie via SFTP en lisant $SFTP_PASS depuis l'environnement
  • Un secret SFTP_PASS configuré dans le repo appelant.

Conventions attendues côté infra Forgejo :

  • Un runner avec le label nixflake mappé vers une image Docker contenant nix (typiquement nixos/nix:latest).
  • network: host dans la config du runner si Forgejo tourne sur la même machine que le runner.

Usage (dans .forgejo/workflows/build-deploy.yml du projet appelant) :

name: build-and-deploy

on:
  push:
    branches:
      - master

jobs:
  call:
    uses: crazy-crafters/ci-workflows/.forgejo/workflows/hugo-static-deploy.yml@master
    secrets:
      SFTP_PASS: ${{ secrets.SFTP_PASS }}

Versionnement

Référencer @master suit la branche : tout changement appliqué ici prend effet au prochain run des projets appelants. Quand le pattern d'un workflow est stabilisé, taguer (v1, v2…) et inviter les projets appelants à pinner sur un tag explicite.

Projets qui utilisent ces workflows

  • olivier_albiez/hypomnemata — site Hugo personnel
  • olivier_albiez/recettes-cuisine — cookbook Cooklang + Hugo