diff options
Diffstat (limited to 'setup-git-web-interface/apache-config.conf')
| -rw-r--r-- | setup-git-web-interface/apache-config.conf | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/setup-git-web-interface/apache-config.conf b/setup-git-web-interface/apache-config.conf new file mode 100644 index 0000000..859699d --- /dev/null +++ b/setup-git-web-interface/apache-config.conf @@ -0,0 +1,70 @@ +# Configuration Apache pour GitLab +# À placer dans /etc/apache2/sites-available/gitlab.conf +# Puis activer avec: sudo a2ensite gitlab.conf + +<VirtualHost *:80> + ServerName chillka.example.com # Remplacer par votre domaine ou IP + + # Redirection vers HTTPS (décommenter après configuration SSL) + # Redirect permanent / https://chillka.example.com/ + + ProxyPreserveHost On + ProxyRequests off + + # Autoriser les requêtes proxy + <Proxy *> + Require all granted + </Proxy> + + # Proxy vers GitLab + ProxyPass / http://127.0.0.1:80/ + ProxyPassReverse / http://127.0.0.1:80/ + + # Headers pour GitLab + RequestHeader set X-Forwarded-Proto "http" + RequestHeader set X-Forwarded-Ssl "off" + + # Headers supplémentaires pour GitLab + RequestHeader set X-Real-IP %{REMOTE_ADDR}s + RequestHeader set X-Forwarded-For %{REMOTE_ADDR}s + + # Logs + ErrorLog ${APACHE_LOG_DIR}/gitlab_error.log + CustomLog ${APACHE_LOG_DIR}/gitlab_access.log combined +</VirtualHost> + +# Configuration HTTPS (décommenter après avoir configuré SSL avec certbot) +# <VirtualHost *:443> +# ServerName chillka.example.com +# +# # SSL Configuration +# SSLEngine on +# SSLCertificateFile /etc/letsencrypt/live/chillka.example.com/fullchain.pem +# SSLCertificateKeyFile /etc/letsencrypt/live/chillka.example.com/privkey.pem +# SSLCertificateChainFile /etc/letsencrypt/live/chillka.example.com/chain.pem +# +# # Protocols et ciphers +# SSLProtocol all -SSLv2 -SSLv3 +# SSLCipherSuite HIGH:!aNULL:!MD5 +# +# ProxyPreserveHost On +# ProxyRequests off +# +# <Proxy *> +# Require all granted +# </Proxy> +# +# ProxyPass / http://127.0.0.1:80/ +# ProxyPassReverse / http://127.0.0.1:80/ +# +# # Headers pour GitLab avec HTTPS +# RequestHeader set X-Forwarded-Proto "https" +# RequestHeader set X-Forwarded-Ssl "on" +# RequestHeader set X-Real-IP %{REMOTE_ADDR}s +# RequestHeader set X-Forwarded-For %{REMOTE_ADDR}s +# +# # Logs +# ErrorLog ${APACHE_LOG_DIR}/gitlab_ssl_error.log +# CustomLog ${APACHE_LOG_DIR}/gitlab_ssl_access.log combined +# </VirtualHost> + |
