How to Homelab: Considerations for adding a Domain to your Gear
Notable Replies
@jay nice job with this video. I have been loving the homelab series, and I appreciated a number of the explanations you gave in this video even though you were not able to give step by step instructions because of the difference in routers that many of us are running.
I have kind of stumbled onto something, but this may not be a wise thing to do. Could you forego a proxy server by installing web services or web apps into sub folders under /var/www/html/
I’m sure there are times when this would not work, but I was thinking that then one web server could serve all of these different web services or sites on your homelab. I just thought it might take away one extra layer of complexity that would come with setting up proxy server. Of course, when you get to “Setting Up a Proxy Server” in your Homelab series we will all be able to do that
Thanks again @jay for your excellent work on your YouTube channel.
It makes for a more brittle system, though, having everything run through just the web server. Plus, in a lot of cases, the web server isn’t as efficient. Add to that it’s more complicated to configure if you pile stuff under the /var/www/html/ folder; most service type stuff has only a few html pages that you’d even want to expose, with the rest being applicationfiles that you definitely don’t want exposed.
It ends up being a lot less complicated to let services stand alone and be proxied. Nginx isn’t hard to set up.
I see your point. My idea wouldn’t work well for those services that you run in a homelab that are less webpage (which might only be a control panel or dashboard of information) and more a service like Nextcloud, Syncthing, PiHole, and others. Often they will start their own webserver and then out put a webpage to localhost:5500 (or some other port number).
I had in mind those hosted apps that are more just a series of webpages that need you to set up a separate LAMP stack to get them to run like Wordpress, sites created with an SSG, or wiki’s. I would think if you have to set up a LAMP for one of them, you could just use the same LAMP stack for all of them and run them in separate folders under /var/www/html/.
A proxy server would be able to give you a direct URL to any of those services, and that would be an advantage not having to remember the port number that the web interface runs on.
Yeah for regular websites, apache lets you do either domain-based or ip-based virtual hosting, too.
I agree with the comments made here, but in general, a proxy server is recommended. Another benefit is that they’re basically disposable. Once you set up a proxy server and you have all the configs tested and all, you can take an image of that server and if it breaks or gets hacked, just delete it and recreate it from the known-good image. It’s a bit less likely for someone to break into the web server if there’s a proxy in front of it, though it can be debated how much extra security that actually gives you.
@jay nice job with this video. I have been loving the homelab series, and I appreciated a number of the explanations you gave in this video even though you were not able to give step by step instructions because of the difference in routers that many of us are running.
I have kind of stumbled onto something, but this may not be a wise thing to do. Could you forego a proxy server by installing web services or web apps into sub folders under
/var/www/html/
Then you could have simple links like:
I’m sure there are times when this would not work, but I was thinking that then one web server could serve all of these different web services or sites on your homelab. I just thought it might take away one extra layer of complexity that would come with setting up proxy server. Of course, when you get to “Setting Up a Proxy Server” in your Homelab series we will all be able to do that
Thanks again @jay for your excellent work on your YouTube channel.
It makes for a more brittle system, though, having everything run through just the web server. Plus, in a lot of cases, the web server isn’t as efficient. Add to that it’s more complicated to configure if you pile stuff under the /var/www/html/ folder; most service type stuff has only a few html pages that you’d even want to expose, with the rest being applicationfiles that you definitely don’t want exposed.
It ends up being a lot less complicated to let services stand alone and be proxied. Nginx isn’t hard to set up.
I see your point. My idea wouldn’t work well for those services that you run in a homelab that are less webpage (which might only be a control panel or dashboard of information) and more a service like Nextcloud, Syncthing, PiHole, and others. Often they will start their own webserver and then out put a webpage to localhost:5500 (or some other port number).
I had in mind those hosted apps that are more just a series of webpages that need you to set up a separate LAMP stack to get them to run like Wordpress, sites created with an SSG, or wiki’s. I would think if you have to set up a LAMP for one of them, you could just use the same LAMP stack for all of them and run them in separate folders under
/var/www/html/
.A proxy server would be able to give you a direct URL to any of those services, and that would be an advantage not having to remember the port number that the web interface runs on.
Yeah for regular websites, apache lets you do either domain-based or ip-based virtual hosting, too.
I agree with the comments made here, but in general, a proxy server is recommended. Another benefit is that they’re basically disposable. Once you set up a proxy server and you have all the configs tested and all, you can take an image of that server and if it breaks or gets hacked, just delete it and recreate it from the known-good image. It’s a bit less likely for someone to break into the web server if there’s a proxy in front of it, though it can be debated how much extra security that actually gives you.