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:
@@ -26,13 +26,13 @@
|
||||
}
|
||||
},
|
||||
"binds": {
|
||||
"mongodb-database": "/var/lib/invoicing/database.json",
|
||||
"s3-bucket": "/var/lib/invoicing/store.json",
|
||||
"route": "/var/lib/invoicing/route.json"
|
||||
"mongodb-database": "${dir:state}/database.json",
|
||||
"s3-bucket": "${dir:state}/store.json",
|
||||
"route": "${dir:state}/route.json"
|
||||
},
|
||||
"secrets": {
|
||||
"mongodb-database": "/var/lib/invoicing/database.secret",
|
||||
"s3-bucket": "/var/lib/invoicing/store.secret"
|
||||
"mongodb-database": "${dir:state}/database.secret",
|
||||
"s3-bucket": "${dir:state}/store.secret"
|
||||
},
|
||||
"listens": [
|
||||
{
|
||||
@@ -60,13 +60,13 @@
|
||||
{
|
||||
"id": "state",
|
||||
"type": "directory",
|
||||
"path": "/var/lib/invoicing",
|
||||
"mode": "0700"
|
||||
"mode": "0700",
|
||||
"place": "."
|
||||
},
|
||||
{
|
||||
"id": "api-env",
|
||||
"type": "file",
|
||||
"path": "/var/lib/invoicing/api.env",
|
||||
"path": "${dir:state}/api.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=${bound:mongodb-database:as}\nMONGO_DB=${bound:mongodb-database:as}\nMINIO_BUCKET=mesh-novox-invoice\nMINIO_ENDPOINT=${bound:s3-bucket:at}\nMINIO_PORT=${bound:s3-bucket:port}\nMINIO_ACCESSKEY=${bound:s3-bucket:as}\nMINIO_SECRET=${secret:s3-bucket}\n"
|
||||
},
|
||||
@@ -103,7 +103,7 @@
|
||||
"GID": "2201"
|
||||
},
|
||||
"env-file": [
|
||||
"/var/lib/invoicing/api.env"
|
||||
"${dir:state}/api.env"
|
||||
],
|
||||
"ports": [
|
||||
"9000"
|
||||
|
||||
Reference in New Issue
Block a user