this post was submitted on 08 Apr 2024
26 points (88.2% liked)

Selfhosted

40218 readers
965 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hi guys! I'm going at my first docker attempt...and I'm going in Proxmox. I created an LXC container, from which I installed docker, and portainer. Portainer seems happy to work, and shows its admin page on port 9443 correctly. I tried next running the image of immich, following the steps detailed in their own guide. This...doesn't seem to open the admin website on port 2283. But then again, it seems to run in its own docker internal network (172.16.0.x). How should I reach immich admin page from another computer in the same network? I'm new to Docker, so I'm not sure how are images supposed to communicate within the normal computer network...Thanks!

you are viewing a single comment's thread
view the rest of the comments
[–] catloaf@lemm.ee 6 points 7 months ago (11 children)

Wait, you're running docker inside lxc? I would not do that. I would create a full VM and run docker in there. Or, if that's all you're running, skip proxmox and install Debian or whatever on bare metal, and docker on that.

[–] iturnedintoanewt@lemm.ee 7 points 7 months ago (10 children)

Sure...But proxmox is already there. It's installed and it runs 5VMs and about 10 containers. ...I'm not going to dump all that just because I need docker...and I'm not getting another machine if I can get use that. So...sure, there might be overhead, but I saw some other people doing it, and the other alternative I saw was running docker on a VM...which is even more overhead. And I fear running it on the proxmox server bare metal, it might conflict with how it manages the LXC containers.

[–] chiisana@lemmy.chiisana.net 5 points 7 months ago (1 children)

Docker inside LXC adds not only the overhead they’d individually add — probably not significant enough for it to matter in a homelab setting — but with it also the added layer of complexity that you’re going to hit when it comes to debugging anything. You’re much better off dropping docker in a full fledged VM instead of running it inside LXC. With a full VM, if nothing else, you can allow the virtual networking to be treated as it’s own separate device on your network, which should reduce a layer of complexity in the problem you’re trying to solve.

As for your original problem… it sounds like you’re not exposing the docker container layer’s network to your host. Without knowing exactly how you’re launching them (beyond the quirky docker inside LXC setup), it is hard to say where the issue may be. If you’re using compose, try setting the network to external, or bridge, and see if you can expose the service’s port that way. Once you’ve got the port exposure thing figured out, you’re probably better off unexposing the service, setup a proper reverse proxy, and wiring the service to go through your reverse proxy instead.

[–] iturnedintoanewt@lemm.ee 1 points 7 months ago

Thanks! When I type my LXC's IP:2283, I get unable to connect. I checked the docker-compose.yml and the port seems to be 2283:3001, but no luck at either. Is there anything that needs to be done on docker's network in order to..."publish" a container to the local network so it can be seen? Or any docker running with a port can be reached via the host's IP with no further config? Checking the portainer's networks section, I can see an 'immich-default' network using bridge on 172.18.0.0/16, while the system's bridge seems to be running at 172.17.0.0/16. Is this the correct defaults? Should I change anything?

Thanks!

load more comments (8 replies)
load more comments (8 replies)