Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Piotr Gawron
minerva-scripts
Commits
7faffcca
Commit
7faffcca
authored
Jan 15, 2020
by
Piotr Gawron
Browse files
when installing make sure that we have IP logged behind proxy
parent
e7262419
Changes
1
Hide whitespace changes
Inline
Side-by-side
server/install.sh
View file @
7faffcca
...
...
@@ -71,6 +71,14 @@ sudo a2enmod ssl
sudo sed
-i
.bak
'/ProxyPass/d'
/etc/apache2/sites-enabled/default-ssl.conf
sudo sed
-i
'3i\ ProxyPass / http://localhost/\n ProxyPassReverse / http://localhost/\n'
/etc/apache2/sites-enabled/default-ssl.conf
#log IPs behind reverse proxy
echo
>>
/etc/apache2/apache2.conf
echo
"RemoteIPHeader X-Forwarded-For"
>>
/etc/apache2/apache2.conf
echo
"RemoteIPTrustedProxy 10.244.9.39"
>>
/etc/apache2/apache2.conf
echo
"RemoteIPInternalProxy 10.244.9.39"
>>
/etc/apache2/apache2.conf
echo
'LogFormat "%a %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined'
>>
/etc/apache2/apache2.conf
a2enmod remoteip
sudo
service apache2 restart
#turn on backups
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment