feat(docker): add migrate-config service for database migrations
Some checks failed
CI / build-and-test (push) Failing after -32m38s

* Include amcs-migrate-config binary in Docker image
* Document migration commands in README
This commit is contained in:
2026-04-21 21:18:34 +02:00
parent 14e218d784
commit 7f9c6f122e
4 changed files with 42 additions and 1 deletions

View File

@@ -654,6 +654,22 @@ Notes:
- Database migrations `001` through `005` run automatically when the Postgres volume is created for the first time.
- `migrations/006_rls_and_grants.sql` is intentionally skipped during container bootstrap because it contains deployment-specific grants for a role named `amcs_user`.
### Run config migration with Compose
The container image now includes `/app/amcs-migrate-config`.
Dry-run (prints migrated YAML, does not write files):
```bash
docker compose --profile tools run --rm migrate-config --config /app/configs/dev.yaml --dry-run
```
Apply migration in-place (writes file + creates backup):
```bash
docker compose --profile tools run --rm migrate-config --config /app/configs/dev.yaml
```
## Ollama
Set your role targets to an Ollama provider to use a local or self-hosted Ollama server through its OpenAI-compatible API.