Cleanup
This commit is contained in:
parent
9e6ae0655a
commit
b873920b6d
|
@ -1 +1 @@
|
||||||
[[ template "common/mv_conf.sh.tpl" dict "ctx" . "services" (dict "smtp-relay" .mail.relay.instance) ]]
|
[[ template "common/mv_conf.sh" dict "ctx" . "services" (dict "smtp-relay" .instance) ]]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[[ $c := merge .mail.relay . -]]
|
[[ $c := merge .mail.relay . -]]
|
||||||
|
|
||||||
job [[ .mail.relay.instance | toJSON ]] {
|
job [[ .instance | toJSON ]] {
|
||||||
|
|
||||||
[[ template "common/job_start.tpl" $c ]]
|
[[ template "common/job_start.tpl" $c ]]
|
||||||
|
|
||||||
|
@ -21,7 +21,7 @@ job [[ .mail.relay.instance | toJSON ]] {
|
||||||
}
|
}
|
||||||
|
|
||||||
service {
|
service {
|
||||||
name = "[[ .mail.relay.instance ]][[ .consul.suffix ]]"
|
name = "[[ .instance ]][[ .consul.suffix ]]"
|
||||||
port = 8025
|
port = 8025
|
||||||
|
|
||||||
[[ template "common/connect.tpl" $c ]]
|
[[ template "common/connect.tpl" $c ]]
|
||||||
|
@ -35,13 +35,13 @@ job [[ .mail.relay.instance | toJSON ]] {
|
||||||
}
|
}
|
||||||
|
|
||||||
vault {
|
vault {
|
||||||
policies = ["[[ .mail.relay.instance ]][[ .consul.suffix ]]"]
|
policies = ["[[ .instance ]][[ .consul.suffix ]]"]
|
||||||
env = false
|
env = false
|
||||||
disable_file = true
|
disable_file = true
|
||||||
}
|
}
|
||||||
|
|
||||||
env {
|
env {
|
||||||
HOSTNAME = "[[ .mail.relay.instance ]].service.[[ .consul.domain ]]"
|
HOSTNAME = "[[ .instance ]].service.[[ .consul.domain ]]"
|
||||||
LOCAL_DOMAINS = ""
|
LOCAL_DOMAINS = ""
|
||||||
RELAY_FROM_HOSTS = "127.0.0.1"
|
RELAY_FROM_HOSTS = "127.0.0.1"
|
||||||
DISABLE_SENDER_VERIFICATION = "true"
|
DISABLE_SENDER_VERIFICATION = "true"
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
---
|
---
|
||||||
|
|
||||||
|
# The Nomad job name
|
||||||
|
instance: smtp-relay
|
||||||
|
|
||||||
mail:
|
mail:
|
||||||
relay:
|
relay:
|
||||||
# The Nomad job name
|
|
||||||
instance: smtp-relay
|
|
||||||
|
|
||||||
# The image to use
|
# The image to use
|
||||||
image: danielberteaud/exim-relay:23.12-1
|
image: '[[ .docker.repo ]]exim-relay:23.12-1'
|
||||||
|
|
||||||
# Number of instances to run
|
# Number of instances to run
|
||||||
count: 1
|
count: 1
|
||||||
|
@ -24,7 +24,7 @@ mail:
|
||||||
port: 587
|
port: 587
|
||||||
tls: True
|
tls: True
|
||||||
user: smtp@example.org
|
user: smtp@example.org
|
||||||
password: '{{ with secret "[[ .vault.prefix ]]kv/service/[[ .mail.relay.instance ]]" }}{{ .Data.data.pwd }}{{ end }}'
|
password: '{{ with secret "[[ .vault.prefix ]]kv/service/[[ .instance ]]" }}{{ .Data.data.pwd }}{{ end }}'
|
||||||
|
|
||||||
# The volume to use for /var/spool/postfix
|
# The volume to use for /var/spool/postfix
|
||||||
volume:
|
volume:
|
||||||
|
|
Loading…
Reference in New Issue