From 8d17a07c9be5cd9d400644c34ea50177535d15f6 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Sat, 24 Dec 2022 22:59:37 +0100 Subject: reorganize some things --- .../telemetry-elastic/deploy/telemetry-system.hcl | 182 +++++++++++++++++++++ .../app/telemetry-elastic/deploy/telemetry.hcl | 181 ++++++++++++++++++++ 2 files changed, 363 insertions(+) create mode 100644 experimental/app/telemetry-elastic/deploy/telemetry-system.hcl create mode 100644 experimental/app/telemetry-elastic/deploy/telemetry.hcl (limited to 'experimental/app/telemetry-elastic/deploy') diff --git a/experimental/app/telemetry-elastic/deploy/telemetry-system.hcl b/experimental/app/telemetry-elastic/deploy/telemetry-system.hcl new file mode 100644 index 0000000..3e26c2e --- /dev/null +++ b/experimental/app/telemetry-elastic/deploy/telemetry-system.hcl @@ -0,0 +1,182 @@ +job "telemetry-system" { + datacenters = ["neptune"] + type = "system" + + group "elasticsearch" { + network { + port "elastic" { + static = 9200 + } + port "elastic_internal" { + static = 9300 + } + } + + task "elastic" { + driver = "docker" + config { + image = "docker.elastic.co/elasticsearch/elasticsearch:8.2.0" + network_mode = "host" + volumes = [ + "/mnt/ssd/telemetry/es_data:/usr/share/elasticsearch/data", + "secrets/elastic-certificates.p12:/usr/share/elasticsearch/config/elastic-certificates.p12", + ] + ports = [ "elastic", "elastic_internal" ] + sysctl = { + #"vm.max_map_count" = "262144", + } + ulimit = { + memlock = "9223372036854775807:9223372036854775807", + } + } + + user = "1000" + + resources { + memory = 1500 + cpu = 500 + } + + template { + data = "{{ key \"secrets/telemetry/elasticsearch/elastic-certificates.p12\" }}" + destination = "secrets/elastic-certificates.p12" + } + + template { + data = <