From f00aaf14cd1b691351cb2d4078023ed4291e3b37 Mon Sep 17 00:00:00 2001 From: Simon L Date: Thu, 10 Aug 2023 11:36:39 +0200 Subject: [PATCH 1/2] add domain-validator Signed-off-by: Simon L --- Containers/mastercontainer/Caddyfile | 11 +++++------ Containers/mastercontainer/supervisord.conf | 8 ++++++++ php/domain-validator.php | 17 +++++++++++++++++ 3 files changed, 30 insertions(+), 6 deletions(-) create mode 100644 php/domain-validator.php diff --git a/Containers/mastercontainer/Caddyfile b/Containers/mastercontainer/Caddyfile index 64b1e8f4..d0806adb 100644 --- a/Containers/mastercontainer/Caddyfile +++ b/Containers/mastercontainer/Caddyfile @@ -14,18 +14,17 @@ servers { protocols h1 h2 h2c } + + on_demand_tls { + ask http://localhost:9876/ + } } http://:80 { redir https://{host}{uri} } -# Match only host names and not ip-addresses: -https://*.*:8443, -https://*.*.*:8443, -https://*.*.*.*:8443, -https://*.*.*.*.*:8443, -https://*.*.*.*.*.*:8443 { +https::8443 { reverse_proxy localhost:8000 diff --git a/Containers/mastercontainer/supervisord.conf b/Containers/mastercontainer/supervisord.conf index 6dc04065..0b60a0d7 100644 --- a/Containers/mastercontainer/supervisord.conf +++ b/Containers/mastercontainer/supervisord.conf @@ -55,3 +55,11 @@ stderr_logfile=/dev/stderr stderr_logfile_maxbytes=0 command=/session-deduplicator.sh user=root + +[program:domain-validator] +stdout_logfile=/dev/stdout +stdout_logfile_maxbytes=0 +stderr_logfile=/dev/stderr +stderr_logfile_maxbytes=0 +command=php -S 127.0.0.1:9876 /var/www/docker-aio/php/domain-validator.php +user=www-data diff --git a/php/domain-validator.php b/php/domain-validator.php new file mode 100644 index 00000000..59d94f16 --- /dev/null +++ b/php/domain-validator.php @@ -0,0 +1,17 @@ + Date: Thu, 10 Aug 2023 13:02:18 +0200 Subject: [PATCH 2/2] address review Signed-off-by: Simon L Co-authored-by: Zoey Signed-off-by: Simon L. --- Containers/mastercontainer/Caddyfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Containers/mastercontainer/Caddyfile b/Containers/mastercontainer/Caddyfile index d0806adb..ba6a281d 100644 --- a/Containers/mastercontainer/Caddyfile +++ b/Containers/mastercontainer/Caddyfile @@ -24,7 +24,7 @@ http://:80 { redir https://{host}{uri} } -https::8443 { +https://:8443 { reverse_proxy localhost:8000