Hi,
Is it possible to use meta tags (in my instance in a group) to use it within the further configuration?
Code snippet:
group "website-prod" {
count = 1
meta {
web-type = "production"
web-fqdn = "production.website.example.com"
}
network {
port "http" {
to = 80
}
}
service {
name = "website-${web-type}"
port = "http"
tags = [
"traefik.enable=true",
"traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https",
"traefik.http.routers.website-${web-type}-redirect.rule=Host(`${web-fqdn}`)",
"traefik.http.routers.website-${web-type}-redirect.entrypoints=http",
"traefik.http.routers.website-${web-type}-redirect.middlewares=redirect-to-https",
"traefik.http.routers.website-${web-type}.tls=true",
"traefik.http.routers.website-${web-type}.entrypoints=https",
"traefik.http.routers.website-${web-type}.rule=Host(`${envy-fqdn}`)",
]
}
}
When I use this, it will just literally put ${web-type}
and ${web-fqdn}
in the job and fail.