A definition names no host path for its own data

Twenty-eight modules' data directories are placed: the root as place ".", a sub-directory named by
its id, and every host-side reference — binds, secrets, own secrets, grants, receives, file paths,
mounts, env-files — as ${dir:<id>}. Resolved on the default root every path is the one the manifest
named before, which the controller's TestPlacedDirectoriesKeepTheirPaths proves over both checkouts;
so no data moves and no machine sees a change. Five directories whose id is not their last segment
keep their path as a placement (novox/hq issue 119, ADR 0112, design 27).
This commit is contained in:
2026-09-30 21:10:18 +02:00
parent 12bbcafacf
commit eed5e8958a
28 changed files with 210 additions and 223 deletions
+9 -9
View File
@@ -22,13 +22,13 @@
}
},
"binds": {
"s3-bucket": "/var/lib/photos/store.json",
"mongodb-database": "/var/lib/photos/database.json",
"route": "/var/lib/photos/route.json"
"s3-bucket": "${dir:state}/store.json",
"mongodb-database": "${dir:state}/database.json",
"route": "${dir:state}/route.json"
},
"secrets": {
"s3-bucket": "/var/lib/photos/store.secret",
"mongodb-database": "/var/lib/photos/database.secret"
"s3-bucket": "${dir:state}/store.secret",
"mongodb-database": "${dir:state}/database.secret"
},
"listens": [
{
@@ -50,13 +50,13 @@
{
"id": "state",
"type": "directory",
"path": "/var/lib/photos",
"mode": "0700"
"mode": "0700",
"place": "."
},
{
"id": "server-env",
"type": "file",
"path": "/var/lib/photos/server.env",
"path": "${dir:state}/server.env",
"mode": "0600",
"content": "NODE_ENV=production\nPORT=9000\nMONGO_URL=mongodb://${bound:mongodb-database:as}:${secret:mongodb-database}@${bound:mongodb-database:at}:${bound:mongodb-database:port}/${bound:mongodb-database:as}?authSource=admin\nMONGO_DB=${bound:mongodb-database:as}\nMINIO_ENDPOINT=${bound:s3-bucket:at}\nMINIO_PORT=${bound:s3-bucket:port}\nMINIO_BUCKET=mesh-novox-photos\nMINIO_ACCESSKEY=${bound:s3-bucket:as}\nMINIO_SECRET=${secret:s3-bucket}\nMINIO_USE_SSL=false\n"
},
@@ -72,7 +72,7 @@
"image": "registry-api.novox.be/novox/photos-server@sha256:3f165acbbd1fd731b12fe798c95879c081a44b00e2c569ef7f47165f6a527201",
"network": "photos",
"env-file": [
"/var/lib/photos/server.env"
"${dir:state}/server.env"
],
"ports": [
"9000"