[ADD] ci: Forgejo Actions CI and Claude bots ported from ecocentral

Same system as ecocentral-18 (see its docs/CI-CD.md):

- ci.yml: lint (pre-commit), test (tools/ci/run_tests.py, OCA-style
  two-phase install) and review (PR bot, after lint and test).
- issue-bot.yml: the issue bot answers issues or opens a PR on bot/issue-N.
- pr-bot.yml: review when WIP is removed or the i18n label is added.
- .gitea/issue-bot.md: context for the bots; this repo is shared by
  several clients.

The bot scripts are copies of ecocentral's. Only the defaults differ (repo,
token and state files, i18n languages es,eu,ca,gl) along with the [I18N]
commit message and the references to the runner's sources.txt.

The jobs run on a second forgejo-runner registration (CriptoMart org) on
ecocentral's runner machine, sharing its image, mounts and cache. The
runner files (Dockerfile, update.sh, sources.txt) live in ecocentral.
Specific to this repo:

- ODOO_SRC_SKIP: the runner's /odoo-src/18.0 holds a clone of addons-cm,
  so test skips it and checks the PR checkout instead.
- BOT_BASE_BRANCH "18.0": the repo's default branch is 16.0.
- test PostgreSQL on port 54330: ecocentral's runs on 54329 and a test job
  from each repo can run at the same time.

The lint job fails until the repo is cleaned up with
pre-commit run --all-files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
GitHub Copilot 2026-10-04 14:14:22 +02:00
parent fad510f69e
commit d9d9e8be2d
Signed by: snt
GPG key ID: A9FD34930EADBE71
13 changed files with 2154 additions and 0 deletions

View file

@ -83,6 +83,22 @@ Ver [docs/LINTERS_README.md](docs/LINTERS_README.md) para configuración complet
Ver [docs/TRANSLATIONS.md](docs/TRANSLATIONS.md).
## CI/CD (Forgejo Actions)
En `.gitea/workflows/`, sobre un runner (etiqueta `issue-bot`) registrado en la organización
CriptoMart en la misma máquina e imagen que el de ecocentral; ver
[tools/issue_bot/README.md](tools/issue_bot/README.md#con-actions):
| Workflow | Cuándo | Qué hace |
| -------- | ------ | -------- |
| `ci.yml` | PR y push a `18.0` | `lint` (pre-commit), `test` ([tools/ci/run_tests.py](tools/ci/run_tests.py)) y `review` (bot de revisión, tras pasar los dos) |
| `issue-bot.yml` | Incidencia abierta o comentada | [Bot de incidencias](tools/issue_bot/README.md): responde o abre un PR en `bot/issue-N` |
| `pr-bot.yml` | Se quita `WIP` o se pone la etiqueta `i18n` | [Bot de revisión](tools/pr_bot/README.md), si el CI ya había pasado |
El contexto que reciben los bots sobre este repo está en [.gitea/issue-bot.md](.gitea/issue-bot.md).
Los repos OCA de los que dependen los tests y la imagen del runner se mantienen en el repo de
ecocentral (`tools/issue_bot/runner/`).
## Documentación técnica
Ver carpeta [docs/](docs/) para documentación transversal (instalación, lazy loading, QWeb, etc.).