diff --git a/assets/runtime/functions b/assets/runtime/functions index 5b4eef74..c84d1e20 100644 --- a/assets/runtime/functions +++ b/assets/runtime/functions @@ -965,15 +965,22 @@ nginx_configure_gitlab_hsts() { fi } -nginx_configure_gitlab_ipv6() { - if [[ ! -f /proc/net/if_inet6 ]]; then - # disable ipv6 support - sed -i \ - -e "/listen \[::\]:80/d" \ - -e "/listen \[::\]:443/d" \ - ${GITLAB_NGINX_CONFIG} - fi -} + nginx_configure_gitlab_ipv6() { + if [[ ! -f /proc/net/if_inet6 ]]; then + # disable ipv6 support in nginx for gitlab + sed -i \ + -e "/listen \[::\]:80/d" \ + -e "/listen \[::\]:443/d" \ + ${GITLAB_NGINX_CONFIG} + # disable ipv6 support in nginx for pages + if [[ ${GITLAB_PAGES_ENABLED} == true ]]; then + sed -i \ + -e "/listen \[::\]:80/d" \ + -e "/listen \[::\]:443/d" \ + ${GITLAB_PAGES_NGINX_CONFIG} + fi + fi + } nginx_configure_gitlab() { echo "Configuring nginx::gitlab..."