Apache Proxy Example

Apache proxy example for web app running on myapp.website.com on port 7990. <VirtualHost *:80> ServerName myapp.website.com ProxyRequests Off <Proxy *> Order deny,allow Allow from all </Proxy> # Logging LogFormat "%h %l %u %t \"%r\" %>s %b" common CustomLog logs/access_

su apache: "This account is currently not available"

When trying to switch user to apache and you get the following: "This account is currently not available". You need to set a shell for the apache user. Let's say we want to use bash. # chsh -s /bin/bash apache You should get this prompt: Changing shell for apache. Shell

Redirect all HTTP request to HTTPS

<VirtualHost *:80> ServerAlias * RewriteEngine On RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [redirect=301] </VirtualHost>