From 8a7bcfe747ce6679ee31d5b266a4301c2b6118e2 Mon Sep 17 00:00:00 2001 From: Simon L Date: Thu, 10 Aug 2023 15:46:40 +0200 Subject: [PATCH] disable logging for domain-validator.php Signed-off-by: Simon L --- Containers/mastercontainer/supervisord.conf | 5 +++-- php/domain-validator.php | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Containers/mastercontainer/supervisord.conf b/Containers/mastercontainer/supervisord.conf index 5bad1235..f64c9725 100644 --- a/Containers/mastercontainer/supervisord.conf +++ b/Containers/mastercontainer/supervisord.conf @@ -57,9 +57,10 @@ command=/session-deduplicator.sh user=root [program:domain-validator] +# Logging is disabled as otherwise all attempts will be logged which spams the logs # stdout_logfile=/dev/stdout # stdout_logfile_maxbytes=0 -stderr_logfile=/dev/stderr -stderr_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 index 83f4fdf2..a1e6487b 100644 --- a/php/domain-validator.php +++ b/php/domain-validator.php @@ -13,6 +13,7 @@ if (strpos($domain, '.') === false) { } elseif (filter_var($domain, FILTER_VALIDATE_IP)) { http_response_code(400); } else { - error_log($domain . ' was accepted as valid domain.'); + // Commented because logging is disabled as otherwise all attempts will be logged which spams the logs + // error_log($domain . ' was accepted as valid domain.'); http_response_code(200); }