User Tools

Site Tools


os:linux:debian:docker

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
os:linux:debian:docker [2017/12/07 15:09] ebaeros:linux:debian:docker [2017/12/07 15:18] (current) ebaer
Line 1: Line 1:
-===== Gitlab && subdomain && ssl =====+===== Gitlab ===== 
 +==== Configure gitlab docker container on apache2 subdomain with ssl ====
  
 <code bash> <code bash>
 # Install everything: # Install everything:
-apt-get install apache2 docker docker-compose python-certbot python-certbot-apache+apt-get install docker docker-compose python-certbot python-certbot-apache
 </code> </code>
  
Line 41: Line 42:
 </code> </code>
  
 +<file bash apache-default.conf>
 +<VirtualHost _default_:80>
 +    ServerName unknown
 +    Redirect 200 /
 +    ErrorDocument 200 "No such site."
 +</VirtualHost>
 +
 +<IfModule mod_ssl.c>
 +<VirtualHost *:443>
 +        ServerName hostname.de
 +        ServerAdmin webmaster@hostname.de
 +
 +        # whatever you want apache to do 
 +
 +        #Include conf-available/serve-cgi-bin.conf
 +        SSLCertificateFile /etc/letsencrypt/live/lieblichknuffeltal.de/fullchain.pem
 +        SSLCertificateKeyFile /etc/letsencrypt/live/lieblichknuffeltal.de/privkey.pem
 +        Include /etc/letsencrypt/options-ssl-apache.conf
 +
 +</VirtualHost>
 +</IfModule>
 +
 +# force ssl
 +<VirtualHost *:80>
 +    ServerName hostname.de
 +    ServerAdmin webmaster@hostname.de
 +
 +    RewriteEngine on
 +    RewriteCond %{SERVER_NAME} =hostname.de
 +    RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,QSA,R=permanent]
 +
 +</VirtualHost>
 +
 +</file>
 +
 +<file bash gitlab.conf>
 +# this is probably redundant
 +<VirtualHost *:80>
 +  ServerName gitlab.hostname.de
 +
 +  RewriteEngine On
 +  RewriteCond %{HTTP_HOST} ^(.+)\.hostname\.de$
 +  RewriteRule ^(.*)$ https://%1.hostname.de/$1 [R=302,L]
 +</VirtualHost>
 +
 +<VirtualHost *:443>
 +    ServerName gitlab.hostname.de
 +    redirect / https://gitlab.hostname.de:8443/
 +
 +    SSLCertificateFile /etc/letsencrypt/live/hostname.de/fullchain.pem
 +    SSLCertificateKeyFile /etc/letsencrypt/live/hostname.de/privkey.pem
 +    Include /etc/letsencrypt/options-ssl-apache.conf
 +
 +</VirtualHost>
 +</conf>
 +</file>
os/linux/debian/docker.1512655793.txt.gz · Last modified: 2017/12/07 15:09 by ebaer

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki