Hello, all. I’ll start this post off with - this is a test. :P I have the same topic posted at /r/… seeing if I get any l<3ve over here!!! I hope so!!! LemmyNet for the WiN!

I have two domains that I pay for… lets call them domain1.com and domain2.com. I’m running a Bitwarden docker container that uses nginx to serve the website… its address is bitwarden.domain1.com .

I’m running a HUGO website with Apache2… its address is domain2.com .

I have one local IP address; currently, I forward ports 80 & 443 to the local IP of the Bitwarden VM. So… thats my issue; I don’t understand how to forward these two different services to the domains that I want them on… I’ve read about Apache2’s vhosts - but the websites are on different VMs, and the Bitwarden docker container uses nginx.

I’ve thought about condensing and putting both services in one VM; but theres still the apache2/nginx issue. I’ve heard someone mention I should use a third VM to route the traffic to the correct local IPs - but I don’t know what software I’d use.

I’ve thought about using a Cloudflare tunnel for one of those services; but I don’t really want to pay, and aren’t sure how fast a free Cloudflare tunnel would be - this might be a solution for the Bitwarden service, as I’m the only one accessing it…

Does anyone have any suggestions? I’m sure I’m just novice enough that I don’t see the obvious solution - and I’d love to get both sites up and running. Thanks for any input or help!!!

pAULIE42o . . . . . . . . . . . /s

  • Mallias
    link
    fedilink
    arrow-up
    2
    ·
    2 years ago

    I’ll give you an example of my setup.

    Every server has it’s own instance of Nginx Proxy Manager (not needed, but helps with using docker networking), then every service I run on docker, I just use docker networks to talk to the rproxy.

    My network is designed such that all my externally available services are on one server, so I just forward 80 & 443 to that.

    For every other service (not on docker), I just use 127.0.0.1 + port.

    For services on other servers on my LAN, I use Internal IP + port.

    • pAULIE42o@beehaw.orgOP
      link
      fedilink
      arrow-up
      1
      ·
      2 years ago

      Understood ; I run all my services on different Proxmox VMs/containers… this isn’t usually an issue until two needed the same 80/443 ports… I suppose I could change the ports for my Bitwarden, as I’m the only user connecting [aside from a partner or 2…] and I could modify the links used to connect accordingly.

      I feel like I’m missing some EASY thing; like can’t my apache2 just route the bitwarden.domain1.com traffic to another local IP address…

      All these replies are helping - I just gotta pick the solution and GO; just trying to find the easiest, best solution… :P