Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (OLD)
- <VirtualHost *:80>
- ServerName www.cryptospora.net
- ServerAlias cryptospora.net
- DocumentRoot /path/to/diaspora/public
- RewriteEngine on
- #disable APACHE commands that are not GET or PUT
- RewriteCond %{REQUEST_METHOD} ^(delete|head|trace|track) [NC]
- RewriteRule ^(.*)$ - [F,L]
- #redirect all www requests to port 443 for encryption
- RedirectPermanent / https://cryptospora.net/
- AllowOverride All
- </VirtualHost>
- (NEW)
- <VirtualHost *:80>
- ServerName www.cryptospora.net
- ServerAlias cryptospora.net
- DocumentRoot /path/to/diaspora/public
- ErrorLog ${APACHE_LOG_DIR}/error.log
- CustomLog ${APACHE_LOG_DIR}/access.log combined
- <Directory /home/locutus/Web/diaspora/diaspora/public>
- Options Indexes FollowSymLinks
- AllowOverride All
- Require all granted
- </Directory>
- RewriteEngine on
- RewriteCond %{SERVER_NAME} =cryptospora.net [OR]
- RewriteCond %{SERVER_NAME} =www.cryptospora.net
- RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
- </VirtualHost>
- (OLD)
- <VirtualHost 127.0.0.1:80>
- DocumentRoot /home/locutus/Web/diaspora/diaspora/public
- RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f
- RewriteRule ^/(.*)$ balancer://thinservers%{REQUEST_URI} [P,QSA,L]
- <Proxy balancer://thinservers>
- BalancerMember http://127.0.0.1:3000
- </Proxy>
- ProxyRequests On
- ProxyVia On
- ProxyPreserveHost On
- ErrorDocument 503 "Cryptospora.net server message: please check back soon."
- ProxyPass / http://localhost:3000/
- ProxyPassReverse / http://localhost:3000/
- <Proxy *>
- Order allow,deny
- Allow from all
- </Proxy>
- <Directory "/home/locutus/Web/diaspora/diaspora/public">
- Options Indexes FollowSymLinks MultiViews Includes ExecCGI
- AllowOverride All
- Order Allow,Deny
- Allow from All
- Options -MultiViews
- </Directory>
- <VirtualHost>
- <IfModule mod_ssl.c>
- <VirtualHost _default_:443>
- SSLEngine On
- SSLProtocol all -SSLv2 -SSLv3
- SSLHonorCipherOrder on
- SSLCipherSuite EECDH+ECDSA+AESGCM:EECDH+aRSA+AESGCM:EECDH+ECDSA+SHA384:EECDH+ECDSA+SHA256:EECDH+aRSA+SHA384:EECDH+aRSA+SHA256:EECDH:EDH+aRSA:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!RC4:!SSLv2:!SSLv3
- SSLCertificateFile /etc/apache2/ssl/cryptospora.net.pem
- SSLCertificateKeyFile /etc/apache2/ssl/cryptospora.key
- SSLCertificateChainFile /etc/apache2/ssl/trust-chain.crt
- SSLCACertificatePath /etc/apache2/ssl/
- RequestHeader set X_FORWARDED_PROTO https
- ServerName www.cryptospora.net
- ServerAlias cryptospora.net
- DocumentRoot /path/to/diaspora/public
- RewriteEngine On
- #force requests to www. to get stripped of the www. prefix (Doesn't work!???)
- RewriteCond %{HTTP_HOST} ^www.cryptospora.net$ [NC]
- RewriteRule ^(.*)$ https://cryptospora.net/$1 [R=301,L]
- RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f
- RewriteRule ^/(.*)$ balancer://thinservers%{REQUEST_URI} [P,QSA,L]
- <Proxy balancer://thinservers>
- BalancerMember http://127.0.0.1:3000
- </Proxy>
- ProxyRequests On
- ProxyVia On
- ProxyPreserveHost On
- ErrorDocument 503 "Cryptospora.net server message: please check back soon."
- ProxyPass / http://localhost:3000/
- ProxyPassReverse / http://localhost:3000/
- <Proxy *>
- Order allow,deny
- Allow from all
- </Proxy>
- <Directory "/path/to/diaspora/public">
- Options Indexes FollowSymLinks MultiViews Includes ExecCGI
- AllowOverride All
- Order Allow,Deny
- Allow from All
- Options -MultiViews
- </Directory>
- </VirtualHost>
- </IfModule>
- (NEW)
- <IfModule mod_ssl.c>
- <VirtualHost *:443>
- ServerName www.cryptospora.net
- ServerAlias cryptospora.net
- DocumentRoot /path/to/diaspora/public
- ErrorLog ${APACHE_LOG_DIR}/error.log
- CustomLog ${APACHE_LOG_DIR}/access.log combined
- PassengerRuby /path/to/.rvm/gems/ruby-2.3.0/wrappers/ruby
- RailsEnv production
- <Directory /path/to/diaspora/public>
- Options FollowSymLinks
- Require all granted
- </Directory>
- Include /etc/letsencrypt/options-ssl-apache.conf
- Include /etc/letsencrypt/options-ssl-apache.conf
- Include /etc/letsencrypt/options-ssl-apache.conf
- SSLCertificateFile /etc/letsencrypt/live/cryptospora.net/cert.pem
- SSLCertificateKeyFile /etc/letsencrypt/live/cryptospora.net/privkey.pem
- SSLCertificateChainFile /etc/letsencrypt/live/cryptospora.net/chain.pem
- </VirtualHost>
- </IfModule>
- # this enables Passenger (in apache.conf)
- LoadModule passenger_module /path/to/.rvm/gems/ruby-2.3.0/gems/passenger-5.1.5/buildout/apache2/mod_passenger.so
- <IfModule mod_passenger.c>
- PassengerRoot /path/.rvm/gems/ruby-2.3.0/gems/passenger-5.1.5
- PassengerDefaultRuby /path/.rvm/gems/ruby-2.3.0/wrappers/ruby
- PassengerMaxPoolSize 10
- PassengerPoolIdleTime 90
- PassengerMaxRequests 10000
- </IfModule>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement