httpd : explicitly bind localhost
[myplc.git] / plc.d / httpd
index 6701223..0e517ce 100755 (executable)
@@ -65,6 +65,10 @@ case "$1" in
            sed -i -e 's,^;date.timezone.*,date.timezone = GMT,' $php_ini
        fi
 
+       if grep '^short_open_tag = Off' $php_ini >& /dev/null; then
+           sed -i -e 's,^short_open_tag = Off,short_open_tag = On,' $php_ini
+       fi
+
        # Disable default Listen directive
        sed -i -e '/^Listen/d' $httpd_conf
 
@@ -113,6 +117,7 @@ case "$1" in
            # HTTP configuration
            if [ $skip_http -eq 0 -a -n "${!http_port}" ] ; then
                cat <<EOF
+Listen 127.0.0.1:${!http_port}
 Listen ${!http_port}
 # create wsgi socket where we have the permission
 ### WSGISocketPrefix run/wsgi