From 4c50dd57f1312f7541cd5b38dc4606d352e5e13a Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Wed, 7 Dec 2022 16:35:21 +0100 Subject: staging: reorganize core services and add D53 --- cluster/staging/app/core/deploy/core-service.hcl | 62 ++++++++ cluster/staging/app/core/deploy/core-system.hcl | 163 +++++++++++++++++++++ cluster/staging/app/core/deploy/core.hcl | 71 --------- cluster/staging/app/directory/deploy/directory.hcl | 2 +- .../app/frontend/deploy/frontend-tricot.hcl | 96 ------------ cluster/staging/app/telemetry/deploy/telemetry.hcl | 6 +- 6 files changed, 231 insertions(+), 169 deletions(-) create mode 100644 cluster/staging/app/core/deploy/core-service.hcl create mode 100644 cluster/staging/app/core/deploy/core-system.hcl delete mode 100644 cluster/staging/app/core/deploy/core.hcl delete mode 100644 cluster/staging/app/frontend/deploy/frontend-tricot.hcl (limited to 'cluster') diff --git a/cluster/staging/app/core/deploy/core-service.hcl b/cluster/staging/app/core/deploy/core-service.hcl new file mode 100644 index 0000000..3f4b343 --- /dev/null +++ b/cluster/staging/app/core/deploy/core-service.hcl @@ -0,0 +1,62 @@ +job "core-service" { + datacenters = ["neptune"] + type = "service" + priority = 90 + + group "D53" { + count = 1 + + task "d53" { + driver = "nix2" + + config { + packages = [ + "git+https://git.deuxfleurs.fr/lx/D53.git?ref=main&rev=ed2653ae7dba9c072dcca1aed03b7cda0d910c85" + ] + command = "d53" + } + + resources { + cpu = 100 + memory = 100 + } + + restart { + interval = "3m" + attempts = 10 + delay = "15s" + mode = "delay" + } + + template { + data = "{{ key \"secrets/consul/consul-ca.crt\" }}" + destination = "etc/tricot/consul-ca.crt" + } + + template { + data = "{{ key \"secrets/consul/consul-client.crt\" }}" + destination = "etc/tricot/consul-client.crt" + } + + template { + data = "{{ key \"secrets/consul/consul-client.key\" }}" + destination = "etc/tricot/consul-client.key" + } + + template { + data = <