Join the community today
Become a Member

VPS with Multiple IP Question

Discussion in 'Install & Upgrades or Pre-Install Questions' started by xaitmi, Dec 13, 2015.

  1. xaitmi

    xaitmi Member

    35
    3
    8
    Jan 18, 2015
    Ratings:
    +3
    Local Time:
    11:51 PM
    Hi.


    I have a BuyVM VPS with 2 IPs.

    1 IP is Regular IP
    1 IP is DDOS Protected IP.

    I installed CentMinMod successfully.

    I edited my domains vhost for it to listen on the DDOS Protected IP.

    When I enter my regular IP in my browser it still connects to the webserver.

    How can I make it so that the webserver only runs on the filtered IP.

    I am only going to use my regular IP to ssh into the box.

    Thanks

    Edit: I did some research and came across this

    configure nginx to listen on single ip address - WebHostingNeeds.com

    It looks like what I am looking for.


    But I'm not sure which nginx.conf to edit

    I ran: "locate nginx.conf" on my server and found these.

    /svr-setup/nginx-1.9.9/conf/nginx.conf
    /usr/local/nginx/conf/nginx.conf
    /usr/local/nginx/conf/nginx.conf.default
    /usr/local/src/centminmod/config/nginx/nginx.conf
     
    Last edited: Dec 13, 2015
  2. rdan

    rdan Well-Known Member

    5,447
    1,408
    113
    May 25, 2014
    Ratings:
    +2,201
    Local Time:
    11:51 AM
    Mainline
    10.2
    Edit this.
    And your domain vhost on /usr/local/nginx/conf/conf.d/
     
  3. xaitmi

    xaitmi Member

    35
    3
    8
    Jan 18, 2015
    Ratings:
    +3
    Local Time:
    11:51 PM
    In
    /usr/local/nginx/conf/nginx.conf
    it does not say listen 80 anywhere.

    should I just add listen myip:80 to the top of the file?
     
  4. eva2000

    eva2000 Administrator Staff Member

    54,934
    12,240
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,812
    Local Time:
    1:51 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+