Change port of nginx vhost

Discussion in 'ISPConfig 3 Priority Support' started by g00fy, Oct 26, 2016.

  1. g00fy

    g00fy New Member


    I use port sharing on my server and therefore I have to change the port of ssl-enabled sites from 443 to 44334. So, I changed this in /usr/local/ispconfig/server/conf/nginx_vhost.conf.master on line 296 and line 298 (did something like this before in ispconfig 3.0). I suposed this would make newly created vhosts with ssl enabled use port 44334 instead of port 443. But unfortunately it does not and I get an error nginx can not be started because the port (443) is in use.
    How can I change my templates so it will make use of port 44334, and how do I preserve it between updates of ispconfig?

    Thanks for helping me out!

  2. till

    till Super Moderator Staff Member ISPConfig Developer

    The https port is set in line 8 and line 13 of the file nginx_vhost.conf.master and the modified master template needs to be put in the folder /usr/local/ispconfig/server/conf-custom/ to make your changes update safe.
  3. g00fy

    g00fy New Member

    Hi Till,

    Thanks for your help.

    I see the https_port is set with a variable in the nginx_vhost.conf.master file. But how do I change the value of this variable? I don't think I can just put the port 44334 there instead of the variable name? I couldn't find where the variables are set?
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    You can do that.

    There should be input fields on the options tab of the website.
  5. g00fy

    g00fy New Member

    Great! I can just change it in the webGUI then. Why was this not mentioned in the manual?
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Tha's an nginx only setting which slipped trough while writing the manual as apache was used for the screenshots. I will add it in the next release of the manual.

Share This Page