{ "module": "de-spiegel", "version": "1", "slug": "spiegel", "capabilities": [ "container-runtime" ], "requires": [ "route", "smtp" ], "contributes": { "route": { "site": { "label": "de-spiegel", "port": 35621 }, "praktijk": { "name": "${config:praktijk-name}", "port": 35621 }, "praktijk-www": { "name": "${config:praktijk-www-name}", "redirect": "https://${config:praktijk-name}" }, "psychologie": { "name": "${config:psychologie-name}", "port": 35621 }, "psychologie-www": { "name": "${config:psychologie-www-name}", "redirect": "https://${config:psychologie-name}" } }, "smtp": { "account": "de-spiegel" } }, "binds": { "route": "/var/lib/de-spiegel/route.json", "smtp": "/var/lib/de-spiegel/smtp.json" }, "config": { "praktijk-name": { "type": "string", "description": "The public name the practice's site is served on; the operator's, with no default (novox/hq ADR 0112).", "trusted": true, "required": true }, "praktijk-www-name": { "type": "string", "description": "The public name that redirects to the practice's site (its www form); the operator's, with no default (novox/hq ADR 0112).", "trusted": true, "required": true }, "psychologie-name": { "type": "string", "description": "The public name the psychology practice's site is served on; the operator's, with no default (novox/hq ADR 0112).", "trusted": true, "required": true }, "psychologie-www-name": { "type": "string", "description": "The public name that redirects to the psychology practice's site (its www form); the operator's, with no default (novox/hq ADR 0112).", "trusted": true, "required": true } }, "listens": [ { "port": 35621, "protocol": "tcp", "from": "mesh", "why": "the de-spiegel site and its /contact endpoint over http; the practice's three public names are route grants, and the proxy reaches every one of them here" } ], "resources": [ { "id": "state", "type": "directory", "path": "/var/lib/de-spiegel", "mode": "0700" }, { "id": "server-env", "type": "file", "path": "/var/lib/de-spiegel/server.env", "mode": "0600", "content": "SMTP_HOST=${bound:smtp:at}\nSMTP_PORT=${bound:smtp:port}\nSMTP_AUTH_USER=de-spiegel@${bound:smtp:domain}\nSMTP_AUTH_PASS=${secret:smtp}\n" }, { "id": "net", "type": "network", "name": "de-spiegel" }, { "id": "server", "type": "container", "name": "de-spiegel", "artifact": "site", "network": "de-spiegel", "env-file": [ "/var/lib/de-spiegel/server.env" ], "ports": [ "35621" ], "secrets-in-environment": "the application's own code reads SMTP_AUTH_USER/PASS from the environment (server/index.js); converting is this repository's change" } ], "build": { "on": [ { "arg": "NODE_BASE", "image": "node@sha256:48e4b67d85f87bd551df43704e24d252f56cc5f8e9718841aace50f19948f0f9" } ], "artifacts": [ { "name": "site", "kind": "image", "from": "Dockerfile" } ] }, "secrets": { "smtp": "/var/lib/de-spiegel/smtp.secret" } }