JonasAlfredsson/docker-nginx-certbot

map variable for server_name

Dunedubby opened this issue · 2 comments

I'm running into trouble using a map block to add some configurability to the server_name, something like:

map $host $server_host {
  default "$SERVER_HOST";
}

in a template file and then

server {
    listen 443 ssl;
    listen [::]:443 ssl;
    
    server_name $server_host;
    etc.
}

Does the code allow for this?

Hi Dunedubby,

I am not exactly sure what you intend to do with this map, but you can probably make use of overrides.

Any more questions or can we close this issue?