forked from hygieia/hygieia
-
Notifications
You must be signed in to change notification settings - Fork 0
/
startup.sh
15 lines (11 loc) · 874 Bytes
/
startup.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/ash
sed -in 's/#LoadModule proxy_module/LoadModule proxy_module/' /usr/local/apache2/conf/httpd.conf
sed -in 's/#LoadModule proxy_http_module/LoadModule proxy_http_module/' /usr/local/apache2/conf/httpd.conf
sed -in 's/#LoadModule ssl_module/LoadModule ssl_module/g' /usr/local/apache2/conf/httpd.conf
sed -in '/<Directory "\/usr\/local\/apache2\/htdocs">/,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /usr/local/apache2/conf/httpd.conf
sed -in 's/#LoadModule rewrite_module/LoadModule rewrite_module/' /usr/local/apache2/conf/httpd.conf
echo "SSLProxyEngine on" >> /usr/local/apache2/conf/httpd.conf
echo "ProxyPass /api $API_URL/api retry=0" >> /usr/local/apache2/conf/httpd.conf
echo "ProxyPass /apiaudit $API_URL/apiaudit retry=0" >> /usr/local/apache2/conf/httpd.conf
echo "TraceEnable off" >> /usr/local/apache2/conf/httpd.conf
httpd-foreground