Skip to content

Setup nginx on Plesk9 server

by admin on March 13th, 2014

How to setup nginx proxy on Plesk9 server:

yum install nginx or install from source

download nginx generate script and unpack.

copy nginx.conf and proxy.conf to nginx conf folder (/etc/nginx).

run sh generate_nginx_conf.sh

check nginx new configuration : nginx -t

make sure you open port 8080 in the firewall.

change apache bind port to 8080 (or another) :

01./usr/local/psa/admin/sbin/websrvmng --set-http-port --port=8080
02./usr/local/psa/admin/sbin/websrvmng --reconfigure-all
03./usr/local/psa/admin/sbin/webmailmng --disable --name=horde
04./usr/local/psa/admin/sbin/webmailmng --enable --name=horde
05./usr/local/psa/admin/sbin/webmailmng --disable --name=atmail
06./usr/local/psa/admin/sbin/webmailmng --enable --name=atmail
07./usr/local/psa/admin/sbin/webmailmng --disable --name=atmailcom
08./usr/local/psa/admin/sbin/webmailmng --enable --name=atmailcom
09.service httpd restart
10.service nginx restart

and you are ready...

you can setup generate_nginx_conf.sh in cron or you can modify it to work with plesk event handlers and also mod_rpaf in apache for statistics http://tech.darke.net/2012/06/06/installing-mod_rpaf-on-rhel-servers/.

No comments yet

Leave a Reply

Note: XHTML is allowed. Your email address will never be published.

Subscribe to this comment feed via RSS