Run the production Vault as three raft nodes on exch and infra-gamma
Two nodes on exch and one on infra-gamma, plain Compose per server, ports on the private addresses only. Nodes unseal through the transit seal on the platform Vault; the transit token reaches only the server process. make prod-images resolves the latest stable Vault release once and pins its digest in ignored .local/prod/images.env, so every node runs the same build. infra/prod/README.md records the layout, the first rollout, node replacement and recovery when the platform Vault is lost (#74).
This commit is contained in:
1 parent
3b551f1565
commit
f436b2528c
11 files changed
+299
-1
No files matched your search
@@ -5,6 +5,7 @@ set -o pipefail
|
||||
. infra/local/scripts/secrets.sh
|
||||
case "${1:-}" in
|
||||
images) . infra/local/scripts/images.sh; images;;
|
||||
prod-images) TOOL_STATE="$PWD/.local"; . infra/local/scripts/images.sh; prod_images;;
|
||||
up) . infra/local/scripts/bootstrap.sh; up;;
|
||||
email) . infra/local/scripts/bootstrap.sh; email;;
|
||||
sendico) . infra/local/scripts/bootstrap.sh; . infra/local/scripts/sendico.sh; configure_sendico;;
|
||||
|
||||
@@ -22,3 +22,10 @@ images() (
|
||||
cat "$WORK/images.env" | write "$STATE/images.env"
|
||||
cat "$STATE/images.env"
|
||||
)
|
||||
# Production pins: one resolution for every node of a cluster, so all of them
|
||||
# run the same build. Written outside .local/dev; copied to the servers.
|
||||
prod_images() (
|
||||
ref=$(image hashicorp/vault latest) || exit 1
|
||||
printf 'VAULT_IMAGE=%s\n' "$ref" | write "$PWD/.local/prod/images.env"
|
||||
cat "$PWD/.local/prod/images.env"
|
||||
)
|
||||
@@ -3,7 +3,7 @@ set -eu
|
||||
set -o pipefail
|
||||
# Shell syntax and static analysis cover the actual container shell scripts.
|
||||
shellcheck -s ash -x -S warning infra/local/scripts/dispatch.sh infra/local/scripts/test.sh
|
||||
shellcheck -x -S warning infra/local/tools.sh infra/local/scripts/start-service.sh infra/local/mongo/start.sh infra/local/nats/start.sh infra/local/vault/start.sh
|
||||
shellcheck -x -S warning infra/local/tools.sh infra/local/scripts/start-service.sh infra/local/mongo/start.sh infra/local/nats/start.sh infra/local/vault/start.sh infra/prod/vault/start.sh
|
||||
shellcheck -s ash -x -S warning infra/local/sendico/session.sh infra/local/sendico/check.sh infra/local/sendico/network.sh
|
||||
. infra/local/scripts/common.sh
|
||||
. infra/local/scripts/images.sh
|
||||
|
||||
Reference in new issue
Block a user