G+_Jason Perry Posted March 20, 2017 Share Posted March 20, 2017 Here is my question I have multiple domain names and one IP address. Am I able to use a port number in my DNS a record? Link to comment Share on other sites More sharing options...
G+_William Frye Posted March 20, 2017 Share Posted March 20, 2017 Jason, you don't set up port numbers on the DNS A record, you setup domain names on the host file, so that when someone tries to access a particular domain, the server knows which folder to serve the domain from :) Link to comment Share on other sites More sharing options...
G+_William Frye Posted March 20, 2017 Share Posted March 20, 2017 Virtual host file(s), sorry, not host file Link to comment Share on other sites More sharing options...
G+_Jason Perry Posted March 20, 2017 Author Share Posted March 20, 2017 I am thinking if I have multiple devices or virtual machines. A virtual host is on a single machine correct? Link to comment Share on other sites More sharing options...
G+_Ben Reese Posted March 20, 2017 Share Posted March 20, 2017 You can host sites with different domain names on a single server - if that's what you're going for. And depending on how you want it to appear to users and want it setup, you can redirect to a specific URL:port. Namecheap offers a few options for this: namecheap.com - Types of Domain Redirects - 301, 302 URL Redirects, URL Frame (and CNAME) (Host records setup) I've used the URL redirect and the cname. URL redirect and URL redirect frame should both let you specify a port number. I believe Apache or nginx will let you host multiple sites on one server. I've been playing with VestaCP that does this very nicely and I've got I think 3 sites running on a dev VPS. Vesta is an open-source control panel similar to Cpanel. My favorite part is integrated LetsEncrypt support. Hope this helps! Link to comment Share on other sites More sharing options...
G+_William Frye Posted March 20, 2017 Share Posted March 20, 2017 you're correct, Jason. Basically, with the virtual host file you tell the machine that if a request is made for a certain domain to serve that domain from a specific folder. Essentially, Domain A would be served from Folder 1, Domain B would be served from Folder 2, and so on.... Link to comment Share on other sites More sharing options...
G+_Jason Perry Posted March 21, 2017 Author Share Posted March 21, 2017 I will have to play with settings in namecheap, at a lack of that I might just use squid as a reverse proxy. Link to comment Share on other sites More sharing options...
G+_Travis Hershberger Posted March 21, 2017 Share Posted March 21, 2017 If you have something like a virtual host with a single public IP address, then you can use a reverse proxy to send the incoming requests to the proper machines. I started setting this up myself, but am having issues with hard drives ? Link to comment Share on other sites More sharing options...
Recommended Posts