Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


hosting 2domains+ on a vps
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

hosting 2domains+ on a vps

Okay so the thing is i'm not a vps expert and let's just say i'm getting started into managing my own vps.

So i've installed on my Linux ubuntu 14.04 vps, nginx - mysql and php. All properly working.
Now i wanna host two domains on it, i changed both domain's nameservers to the vps's ip.

I checked some tutorials but i'm getting a little bit confused. Something to do with /sites-available/default ?

Thanks in advance.

Comments

  • Install vestacp on it and you can manage your hosting needs easier.

  • IkoulaIkoula Member, Host Rep

    Hello,

    Where do you manage your domain dns zones ?

  • @mrdarki said:
    Okay so the thing is i'm not a vps expert

    Expertise is not required, but a decent admin background is. It's a steep learning curve if you don't have a lot of experience putzing around on the command line as a regular user.

    I checked some tutorials but i'm getting a little bit confused. Something to do with /sites-available/default ?

    Sounds more like an Apache configuration than nginx. If you can't puzzle out the tutorials, you might be in over your head. You want to set up virtual servers.

  • If it's Apache then what you need is virtualhost, i dont know what is called on nginx.

  • painfreepcpainfreepc Member
    edited November 2016

    I think it's been over a year since I last logged in here,

    As someone has already stated the easiest way to manage your server is "vestacp"
    It's ridiculously easy to install and it just works I have used it for over a year at digital ocean and I have not had any problems.

    I point my domain registry to digital ocean and let digitalocean handle the DNS records for all my websites, it can't get any easier than that and manage the website and database with vestacp,

    There are lots of ways to do it for example I don't have to use digitalocean to handle the DNS records I could just use one of my domains as the name server that use vestacp to handle the records,

    There's lots of tutorials online to help you with this, don't let some of the hard core guys here scare you you don't need to learn command lines to run a basic website,

    Vestacp can get the website set up for you but you do need to understand the basics of DNS to to get that set up correctly,..


    Oh wow I got to remove that signature, I stop doing that a long time ago..

  • Okay just got back home, so the thing is the tutorials i have been seen are for nginx not apache @impossiblystupid , i did follow them step by step but somehow it went bad.

    I know it's easier with a control panel like vesta, and i know how to do it with vesta, what if i need just to run a few websites on my vps without using a control panel? That's why i made this thread.

  • @impossiblystupid said:
    Sounds more like an Apache configuration than nginx. If you can't puzzle out the tutorials, you might be in over your head. You want to set up virtual servers.

    If I recall correctly, older version of nginx uses sites-available sites-enabled folder structure. The newer nginx changed to conf.d folder, which is much cleaner.

    Thanked by 1impossiblystupid
  • I'm still using the site-enabled structure which I myself feel comfortable with.

    Basically you need to download the default file, open it with a decent text editor. You should be able to understand what it talks about. Now change the options like server_name and root, rename it to something else, then upload it back. After reloading the nginx config, it should just work.

  • ivanhivanh Member
    edited November 2016

    Heres something basic, pretty much cut and paste: https://www.digitalocean.com/community/tutorials/how-to-set-up-nginx-server-blocks-virtual-hosts-on-ubuntu-14-04-lts

    Read the prereq to install a LEMP stack if you haven't already

  • I don't think you should change both domain's nameservers to the vps's ip unless the vps also act as the dns server which hosts the zone files for these two domains.

  • mrdarki said: i changed both domain's nameservers to the vps's ip

    I wouldn't encourage you to do this, because using a single VPS to host DNS records lacks redundancy and stability. You can try using some third party DNS and create records pointing your domains to the VPS. To make your life easier I'd also recommend some management panels such as VestaCP or Webmin/Virtualmin.

  • As it was already mentioned, Webmin/Virtualmin can do this for you. The only problem you already have a running website. Not sure if Webmin/Virtualmin is going to be able to handle the existing configuration. It's probably best to install Webmin/Virtualmin on a clean VPS, create virtual servers and start migrating your websites to them. There is also a lot of docs and tutorials that can be helpfull.

  • this is how I am doing it:

    create dns with cloudflare and point them to my vps ip, edit domain dns via domain panel to cloudflare dns, and I am managing my vps/sites via centminmod or vpssim.

    cant be easier I guess?

Sign In or Register to comment.