CI / test-and-build (push) Failing after 51s
.github/workflows/ci.yml nunca corrió: Gitea Actions busca los workflows en .gitea/workflows/, no en .github/workflows/, y además no había ningún runner registrado en la instancia (0 workflow_runs históricos). Se registró un runner en modo host en mcps-hpc-01 (mismo binario act_runner, sin Docker-in-Docker) y se agregó un paso de publicación al final del pipeline: en push a main, hace rsync de public/ a /opt/clusterlog/public/, que sirve un contenedor nginx en mcps-net detrás de Caddy en clusterlog.mcps-epcm.org. También corrige base_url en zola.toml, que seguía apuntando al dominio de ejemplo.
71 lines
1.7 KiB
YAML
71 lines
1.7 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
test-and-build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: go.mod
|
|
cache: true
|
|
|
|
- name: Instalar Zola fijado
|
|
uses: taiki-e/install-action@v2
|
|
with:
|
|
tool: zola@0.23.3
|
|
fallback: none
|
|
|
|
- name: Preparar tema fijado
|
|
run: ./scripts/bootstrap-theme.sh
|
|
|
|
- name: Formato Go
|
|
run: test -z "$(gofmt -l cmd internal)"
|
|
|
|
- name: Pruebas Go
|
|
run: go test ./...
|
|
|
|
- name: Detector de carreras Go
|
|
run: go test -race ./...
|
|
|
|
- name: Análisis estático Go
|
|
run: go vet ./...
|
|
|
|
- name: Compilar CLI
|
|
run: make build
|
|
|
|
- name: Flujo integral de la CLI
|
|
run: ./scripts/e2e-local.sh
|
|
|
|
- name: Verificar firmas SSH de commits del pull request
|
|
if: github.event_name == 'pull_request'
|
|
env:
|
|
BASE_SHA: ${{ github.event.pull_request.base.sha }}
|
|
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
|
|
run: ./scripts/verify-signatures-ci.sh
|
|
|
|
- name: Regenerar y comprobar proyección
|
|
run: |
|
|
./bin/clusterlog --root . sync
|
|
./bin/clusterlog --root . sync --check
|
|
|
|
- name: Validar contenido y plantillas
|
|
run: ./bin/clusterlog --root . validate --require-zola
|
|
|
|
- name: Construir sitio
|
|
run: zola build
|
|
|
|
- name: Publicar en producción (clusterlog.mcps-epcm.org)
|
|
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
|
|
run: rsync -a --delete public/ /opt/clusterlog/public/
|