feat: bootstrap solution, Docker image and Gitea pipelines (M0)
CI / Build and test (SQLite) (pull_request) Successful in 43s
CI / PostgreSQL 16 integration (pull_request) Skipped
CI / PostgreSQL 17 integration (pull_request) Skipped
CI / YAML check (pull_request) Successful in 15s
CI / Docker image (pull_request) Successful in 59s
CI / Build and test (SQLite) (pull_request) Successful in 43s
CI / PostgreSQL 16 integration (pull_request) Skipped
CI / PostgreSQL 17 integration (pull_request) Skipped
CI / YAML check (pull_request) Successful in 15s
CI / Docker image (pull_request) Successful in 59s
Start development with the skeleton every later milestone builds on, so that code, image and release path exist and are verified from day one. - Khaemhat.sln with the ten projects of SPEC section 3 and six MSTest projects; shared build rules with warnings as errors, analyzers and Central Package Management restricted to the allowlist. - Architecture tests and scripts/check-packages.sh fail on any project reference or package that SPEC does not allow. - Khaemhat.Web serves an Italian "under construction" page with the official icons and version, plus /health/live, /health/ready and /health (ADR 0012); honours KHAEMHAT_URLS and KHAEMHAT_LOG_LEVEL. - docker/Dockerfile (non-root app user aligned to PUID/PGID by the entrypoint, pg_dump 17, healthcheck, OCI and Unraid labels) and compose files for PostgreSQL and a standalone SQLite demo. - Gitea Actions: ci.yml (build, tests, image smoke test, PostgreSQL 16/17 on tags, YAML check), release.yml (image and release from a vX.Y.Z tag, skipping versions already published) and wiki.yml. - Development scripts, VS Code launch/tasks for debugging, and ADR 0012-0017 deciding the M0 open points of docs/STATUS.md. Closes #1, #2, #3, #4, #5, #114 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
88de272b3e
commit
12277733f5
101 files changed
+3245
-67
No files matched your search
@@ -65,13 +65,14 @@ Regole pratiche:
|
||||
|
||||
### Il file compose
|
||||
|
||||
Il file definitivo è `deploy/docker-compose.yml` nel repository (sarà creato nella milestone M0). La struttura
|
||||
prevista è questa: applicazione, `postgres:17` e `redis:7` attivabile con un profilo.
|
||||
Il file è [`deploy/docker-compose.yml`](https://gitea.encke-hake.ts.net/BalboSoft/Khaemhat/src/branch/main/deploy/docker-compose.yml)
|
||||
nel repository: applicazione, `postgres:17` e `redis:7` attivabile con un profilo. La versione dell'immagine si
|
||||
sceglie con `KHAEMHAT_VERSION` nel `.env`. In sintesi:
|
||||
|
||||
```yaml
|
||||
services:
|
||||
khaemhat:
|
||||
image: gitea.encke-hake.ts.net/balbosoft/khaemhat:1.0.0
|
||||
image: gitea.encke-hake.ts.net/balbosoft/khaemhat:${KHAEMHAT_VERSION:-0.0.1}
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
khaemhat-db: { condition: service_healthy }
|
||||
@@ -128,12 +129,12 @@ Note:
|
||||
## Demo autonoma con SQLite
|
||||
|
||||
Per provare Khaemhat senza PostgreSQL esiste `deploy/docker-compose.sqlite.yml`: un solo container, database di
|
||||
sistema e aziende come file SQLite nel volume `/data`, dati di esempio caricati al primo avvio. Struttura prevista:
|
||||
sistema e aziende come file SQLite nel volume `/data`, dati di esempio caricati al primo avvio. In sintesi:
|
||||
|
||||
```yaml
|
||||
services:
|
||||
khaemhat:
|
||||
image: gitea.encke-hake.ts.net/balbosoft/khaemhat:1.0.0
|
||||
image: gitea.encke-hake.ts.net/balbosoft/khaemhat:${KHAEMHAT_VERSION:-0.0.1}
|
||||
ports: ["8080:8080"]
|
||||
environment:
|
||||
KHAEMHAT_SYSTEM_DB: sqlite:///data/system.db
|
||||
@@ -189,7 +190,7 @@ obbligatoria, termina con un messaggio che indica quale.
|
||||
| `KHAEMHAT_UPDATE_FEED` | no | `https://gitea.encke-hake.ts.net/api/v1/packages/BalboSoft?type=container&q=khaemhat` | API dei pacchetti Gitea per il controllo aggiornamenti |
|
||||
| `KHAEMHAT_UPDATE_TOKEN` | no | token Gitea in sola lettura | solo se il pacchetto non è pubblico |
|
||||
| `TZ` | no | `Europe/Rome` | fuso orario |
|
||||
| `PUID` / `PGID` | no | `99` / `100` | utente e gruppo proprietari dei file in `/data` |
|
||||
| `PUID` / `PGID` | no | `1654` / `1654` (Unraid: `99` / `100`) | utente e gruppo proprietari dei file in `/data`; l'applicazione non gira mai come root |
|
||||
|
||||
Le variabili del super utente e della prima azienda sono lette solo al primo avvio (quando le tabelle
|
||||
corrispondenti sono vuote): cambiarle dopo non ha effetto. `KHAEMHAT_TEST_PG` e `KHAEMHAT_TEST_REDIS` servono solo
|
||||
@@ -198,8 +199,11 @@ ai test automatici e non vanno impostate in un'installazione.
|
||||
## Docker secrets
|
||||
|
||||
Per non scrivere le password in chiaro nel file compose, le variabili sensibili ammettono la variante `_FILE`: invece
|
||||
del valore contengono il percorso di un file da cui leggerlo. La specifica la prevede per `KHAEMHAT_SYSTEM_DB` e per
|
||||
le variabili `KHAEMHAT_SUPERUSER_*`; l'elenco completo delle variabili che la accettano sarà fissato in sviluppo.
|
||||
del valore contengono il percorso di un file da cui leggerlo. La accettano tutte le variabili sensibili: `KHAEMHAT_SYSTEM_DB`,
|
||||
`KHAEMHAT_DB_SERVER`, `KHAEMHAT_SECRET_KEY`, `KHAEMHAT_SECRET_KEY_NEW`, `KHAEMHAT_SUPERUSER`,
|
||||
`KHAEMHAT_SUPERUSER_PASSWORD`, `KHAEMHAT_SUPERUSER_EMAIL`, `KHAEMHAT_LICENSE`, `KHAEMHAT_REDIS`,
|
||||
`KHAEMHAT_SMTP_PASSWORD`, `KHAEMHAT_UPDATE_TOKEN`. Il valore è il contenuto del file senza il fine riga finale;
|
||||
impostare insieme `X` e `X_FILE` è un errore che ferma l'avvio.
|
||||
|
||||
```yaml
|
||||
services:
|
||||
|
||||
Reference in new issue
Block a user