diff --git a/docs/en_US/server_deployment.rst b/docs/en_US/server_deployment.rst index 81ffae48..d85efce6 100644 --- a/docs/en_US/server_deployment.rst +++ b/docs/en_US/server_deployment.rst @@ -148,6 +148,9 @@ Apache HTTPD Configuration (Linux/Unix) Once Apache HTTP has been configured to support ``mod_wsgi``, the pgAdmin application may be configured similarly to the example below: +**Note:** If you'r using ``WSGIScriptAlias`` with some parameter e.g: ``WSGIScriptAlias /pgadmin4 /opt/pgAdmin4/web/pgAdmin4.wsgi``, +you need to set ``ProxyPass /socket.io/ url/pgadmin4/socket.io/ ProxyPassReverse /socket.io/ url/pgadmin4/socket.io/`` + .. code-block:: apache diff --git a/pkg/debian/pgadmin4.conf b/pkg/debian/pgadmin4.conf index d31a3e40..47312f44 100644 --- a/pkg/debian/pgadmin4.conf +++ b/pkg/debian/pgadmin4.conf @@ -1,9 +1,13 @@ -WSGIDaemonProcess pgadmin processes=1 threads=25 python-home=/usr/pgadmin4/venv -WSGIScriptAlias /pgadmin4 /usr/pgadmin4/web/pgAdmin4.wsgi + + WSGIDaemonProcess pgadmin processes=1 threads=25 python-home=/usr/pgadmin4/venv + WSGIScriptAlias /pgadmin4 /usr/pgadmin4/web/pgAdmin4.wsgi - + WSGIProcessGroup pgadmin WSGIApplicationGroup %{GLOBAL} Require all granted - + + ProxyPass /socket.io/ http://127.0.0.1:80/pgadmin4/socket.io/ + ProxyPassReverse /socket.io/ http://127.0.0.1:80/pgadmin4/socket.io/ + diff --git a/pkg/redhat/pgadmin4.conf b/pkg/redhat/pgadmin4.conf index 3373c8ad..f79eaa43 100644 --- a/pkg/redhat/pgadmin4.conf +++ b/pkg/redhat/pgadmin4.conf @@ -1,19 +1,24 @@ -LoadModule wsgi_module modules/mod_wsgi.so -WSGIDaemonProcess pgadmin processes=1 threads=25 python-home=/usr/pgadmin4/venv -WSGIScriptAlias /pgadmin4 /usr/pgadmin4/web/pgAdmin4.wsgi + + LoadModule wsgi_module modules/mod_wsgi.so + WSGIDaemonProcess pgadmin processes=1 threads=25 python-home=/usr/pgadmin4/venv + WSGIScriptAlias /pgadmin4 /usr/pgadmin4/web/pgAdmin4.wsgi - - WSGIProcessGroup pgadmin - WSGIApplicationGroup %{GLOBAL} - - # Apache 2.4 - Require all granted - - - # Apache 2.2 - Order Deny,Allow - Deny from All - Allow from 127.0.0.1 - Allow from ::1 - - + + WSGIProcessGroup pgadmin + WSGIApplicationGroup %{GLOBAL} + + # Apache 2.4 + Require all granted + + + # Apache 2.2 + Order Deny,Allow + Deny from All + Allow from 127.0.0.1 + Allow from ::1 + + + + ProxyPass /socket.io/ http://127.0.0.1:80/pgadmin4/socket.io/ + ProxyPassReverse /socket.io/ http://127.0.0.1:80/pgadmin4/socket.io/ + \ No newline at end of file