From da1e696292e06cd2924e7f210c432869ea843b31 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Wed, 20 Oct 2021 17:39:21 +0200 Subject: [PATCH] Fix https redirect setting Fixed the reverse setting for https redirection. It would redirect when the option was toggled off and vice versa. --- roles/caddy/templates/config.json.j2 | 4 ++-- roles/caddy/vars/main.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/roles/caddy/templates/config.json.j2 b/roles/caddy/templates/config.json.j2 index ea70f49..0be7e06 100644 --- a/roles/caddy/templates/config.json.j2 +++ b/roles/caddy/templates/config.json.j2 @@ -21,7 +21,7 @@ ":80" ], "routes": [] -{% if caddy_use_https is sameas true %}, +{% if caddy_use_https is sameas false %}, "automatic_https": { "disable": true } @@ -32,7 +32,7 @@ ":443" ], "routes": [] -{% if caddy_use_https is sameas true %}, +{% if caddy_use_https is sameas false %}, "automatic_https": { "disable": true } diff --git a/roles/caddy/vars/main.yml b/roles/caddy/vars/main.yml index f3bcca6..1f6237e 100644 --- a/roles/caddy/vars/main.yml +++ b/roles/caddy/vars/main.yml @@ -4,5 +4,5 @@ caddy_stack: name: caddy compose: "{{ lookup('template', 'docker-stack.yml.j2') | from_yaml }}" -caddy_http_server_name: http -caddy_https_server_name: https +caddy_http_server_name: httpserve +caddy_https_server_name: httpsserve