diff --git a/root/etc/s6-overlay/s6-rc.d/svc-apache/run b/root/etc/s6-overlay/s6-rc.d/svc-apache/run index 105c452..41cc18b 100755 --- a/root/etc/s6-overlay/s6-rc.d/svc-apache/run +++ b/root/etc/s6-overlay/s6-rc.d/svc-apache/run @@ -2,7 +2,10 @@ # shellcheck shell=bash if [[ -f "/config/httpd.conf" ]]; then - PORT=$(grep -e "^Listen" /config/httpd.conf | awk -F ' ' '{print $2}') + PORT=$(grep -e "^Listen" /config/httpd.conf \ + | awk '{print $2}' \ + | awk -F: '{print $NF}' \ + | head -n1) fi exec \