diff options
-rw-r--r-- | app/deployment/directory.hcl (renamed from app/deployment/bottin2.hcl) | 40 |
1 files changed, 18 insertions, 22 deletions
diff --git a/app/deployment/bottin2.hcl b/app/deployment/directory.hcl index fec7d74..0acc08f 100644 --- a/app/deployment/bottin2.hcl +++ b/app/deployment/directory.hcl @@ -1,4 +1,4 @@ -job "directory2" { +job "directory" { datacenters = ["dc1"] type = "service" priority = 90 @@ -10,15 +10,21 @@ job "directory2" { group "bottin" { count = 1 + + network { + port "ldap_port" { + static = 389 + to = 389 + } + } + task "bottin" { driver = "docker" config { image = "lxpz/bottin_amd64:20" network_mode = "host" readonly_rootfs = true - port_map { - ldap_port = 389 - } + ports = [ "ldap_port" ] volumes = [ "secrets/config.json:/config.json" ] @@ -26,15 +32,10 @@ job "directory2" { resources { memory = 100 - network { - port "ldap_port" { - static = "389" - } - } } template { - data = "{{ key \"configuration/directory/bottin/config.json\" }}" + data = file("../config/configuration/directory/bottin/config.json") destination = "secrets/config.json" } @@ -60,34 +61,29 @@ job "directory2" { group "guichet" { count = 1 + + network { + port "web_port" { to = 9991 } + } + task "guichet" { driver = "docker" config { image = "lxpz/guichet_amd64:10" readonly_rootfs = true - port_map { - web_port = 9991 - } + ports = [ "web_port" ] volumes = [ "secrets/config.json:/config.json" ] } - artifact { - source = "http://127.0.0.1:8500/v1/kv/configuration/directory/guichet/config.json.tpl?raw" - destination = "secrets/config.json.tpl" - mode = "file" - } template { - source = "secrets/config.json.tpl" + data = file("../config/configuration/directory/guichet/config.json.tpl") destination = "secrets/config.json" } resources { memory = 200 - network { - port "web_port" {} - } } service { |