feat(R4b): reproducible builds — pin requirements.lock checksum
- Dockerfile: build-arg REQUIREMENTS_CHECKSUM verifica lo sha256 del lockfile (fallisce la build se non coincide; vuoto = skip locale) - docker-compose.yml: default = hash corrente del lock - CI: nuovo job checksum.yml che fallisce se il pin non coincide - Fix YAML preesistente in ci.yml (name: con ':' non quotati) - Docs: README, .env.example, review aggiornati
This commit is contained in:
1 parent
0f15b7958f
commit
12d2018ac5
7 files changed
+78
-10
No files matched your search
@@ -61,6 +61,17 @@ pip install pip-tools
|
||||
pip-compile --strip-extras --no-hash --output-file requirements.lock requirements.txt
|
||||
```
|
||||
|
||||
La build Docker verifica che `requirements.lock` coincida con l'hash pinnato
|
||||
in `docker-compose.yml` (`REQUIREMENTS_CHECKSUM`, R4b): se aggiorni le
|
||||
dipendenze, aggiorna anche il pin:
|
||||
|
||||
```bash
|
||||
sed -i "s/[a-f0-9]\{64\}/$(sha256sum requirements.lock | awk '{print $1}')/" docker-compose.yml
|
||||
```
|
||||
|
||||
(trova la riga `REQUIREMENTS_CHECKSUM:` — primo hash del file). La CI
|
||||
(`.github/workflows/checksum.yml`) fallisce se il pin non coincide col lock.
|
||||
|
||||
## Note sul container
|
||||
|
||||
- Gunicorn, 1 worker + thread: i task SSE vivono in memoria del processo.
|
||||
|
||||
Reference in new issue
Block a user