SHARE
TWEET

Kanboard-Server

Zockerjonny Feb 17th, 2020 (edited) 34 in 135 days
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. sudo mkdir /mnt/letsencrypt
  2. sudo nano /etc/fstab
  3. ############################################
  4. # NFS
  5. IP-OF-PROXY-SERVER:/etc/letsencrypt /mnt/letsencrypt nfs auto 0 0
  6. ############################################
  7.  
  8. sudo mount -a
  9. cd /etc/apache2/sites-available/
  10. sudo mv 000-default.conf 000-default.conf.back  #Backup of default config
  11. sudo nano 000-default.conf
  12.  
  13. ############################################
  14.   GNU nano 2.9.3       /etc/apache2/sites-available/000-default.conf                                                                      
  15. <VirtualHost *:80>
  16. ServerAdmin webmaster@localhost
  17. DocumentRoot /var/www/html
  18. ErrorLog /var/log/apache2/vhost1-error.log
  19. <Location />
  20. RewriteEngine on
  21. RewriteCond %{HTTPS} off
  22. RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R]
  23. </Location>
  24. </VirtualHost>
  25. <VirtualHost *:443>
  26. ServerAdmin webmaster@localhost
  27. DocumentRoot /var/www/html
  28. ErrorLog /var/log/apache2/vhost1-error.log
  29. CustomLog /var/log/apache2/vhost1-access.log combined
  30. SSLEngine On
  31. SSLCertificateFile /mnt/letsencrypt/live/example.net/fullchain.pem
  32. SSLCertificateKeyFile /mnt/letsencrypt/live/example.net/privkey.pem
  33. <Location />
  34. SSLRequireSSL On
  35. SSLVerifyClient optional
  36. SSLVerifyDepth 1
  37. SSLOptions +StdEnvVars +StrictRequire
  38. </Location>
  39. </VirtualHost>
  40. ############################################
  41. sudo reboot
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top