• The new Python extension is now available. It allows customers to deploy and manage WSGI-based Python applications on their websites directly from Plesk.
  • The Plesk Mobile apps for iOS and Android and the Plesk Mobile Center extension have been deprecated, and are no longer available for new installations. In Plesk Obsidian 18.0.84, the Plesk Mobile Center extension will be removed from servers during the upgrade, and the Plesk Mobile apps will lose their server management features.
  • The Social Login extension has been deprecated and will be removed in Plesk Obsidian 18.0.84. After that, it will no longer be possible to log in to Plesk with a Google, Facebook, GitHub account, or with a passkey. Plesk usernames and passwords, as well as logging in with a WebPros Account, are not affected.

Question How can I permanently remove Nginx from Port 80?

Lethalmiko

New Pleskian
The Plesk documentation and other online discussion threads say that to change the listening ports of the webserver, you use templates, but all the instructions to change the port Nginx listens on have failed to remove it from port 80. All they do is add an extra port for listening to. I use Nginx as a frontline server (not as a reverse proxy to Apache). The instructions say to make copies of 6 Nginx template files and put them into a custom directory and edit them. ie

# mkdir /usr/local/psa/admin/conf/templates/custom/
# cp /usr/local/psa/admin/conf/templates/default/nginx* /usr/local/psa/admin/conf/templates/custom/
# mkdir /usr/local/psa/admin/conf/templates/custom/webmail/
# cp /usr/local/psa/admin/conf/templates/default/webmail/nginxWebmail.php /usr/local/psa/admin/conf/templates/custom/webmail/

List of files to edit:

nginxDomainForwardingIpDefault.php
nginxDomainForwarding.php
nginxDomainVhostIpDefault.php
nginxDomainVhost.php
nginx.php
nginxWebmail.php

I looked for the line:

'ssl' => false,
'frontendPort' => $VAR->server->nginx->httpPort,

Changed to this:

'ssl' => false,
'frontendPort' => "8888",

Then:

# /usr/local/psa/admin/bin/httpdmng --reconfigure-all
# /etc/init.d/nginx restart

But after all this, Nginx still binds to port 80. All the instructions on the threads I found online (including the Plesk forums) on this topic simply DO NOT WORK!!!

eg this thread: [Solved] help required - change nginx port

Here is what happens:

# netstat -nlpt | grep nginx
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 30019/nginx: master
tcp 0 0 x.x.x.x:8888 0.0.0.0:* LISTEN 30019/nginx: master
tcp 0 0 x.x.x.x:443 0.0.0.0:* LISTEN 30019/nginx: master

I use ‪Ubuntu 18.04.3 LTS‬ and Plesk Onyx 17.8.11 Update #81.

Someone please HELP!!!
 
Last edited:
It turns out that all the instructions for changing the listening port for either Apache or Nginx do not work. For example this guide in the documentation doesn't work:


I disabled Nginx from the Plesk Panel, then changed the Apache port in 14 files as per instructions. Regenerated system files, restarted Apache but it still blocks Port 80. If I stop Apache and start a caching server in front of it on port 80, Apache refuses to start. List of custom template files:

/usr/local/psa/admin/conf/templates/custom/domain/domainVirtualHost.php
/usr/local/psa/admin/conf/templates/custom/domain/frameForwarding.php
/usr/local/psa/admin/conf/templates/custom/server/mailman.php
/usr/local/psa/admin/conf/templates/custom/server/nameVirtualHost.php
/usr/local/psa/admin/conf/templates/custom/nginx.php
/usr/local/psa/admin/conf/templates/custom/nginxDomainForwarding.php
/usr/local/psa/admin/conf/templates/custom/nginxDomainForwardingIpDefault.php
/usr/local/psa/admin/conf/templates/custom/nginxDomainVhost.php
/usr/local/psa/admin/conf/templates/custom/nginxDomainVhostIpDefault.php
/usr/local/psa/admin/conf/templates/custom/webmail/nginxWebmail.php
/usr/local/psa/admin/conf/templates/custom/server/pleskServiceLocaldomain.php
/usr/local/psa/admin/conf/templates/custom/domain/standardForwarding.php
/usr/local/psa/admin/conf/templates/custom/server/vhosts.php
/usr/local/psa/admin/conf/templates/custom/webmail/webmail.php

I really don't understand why instructions that don't work have been put into official documentation. :(
 
Back
Top