pirateMonkey

joined 2 months ago
[–] pirateMonkey@lemmy.world 1 points 1 week ago (1 children)

I may be (probably am) worrying too much about this, but doesn't that remove much of the benefit of running services in containers? My understanding is that one benefit of containerization is so that if one service is somehow compromised, the others remain isolated, but running the service that allows you inside on bare metal gives single point access to the drives that those other services rely on, and that's from the most likely point someone could get into your network. Alternatively, if Tailscale is containerized and someone gets in, they have access to the other services' front ends but not the data they rely on since Tailscale itself doesn't have that access.

[–] pirateMonkey@lemmy.world 1 points 1 week ago* (last edited 1 week ago)

Yes, I believe I made the stupid mistake of not restarting after enabling. Once I did that the warning went away and I was able to enable subnets, but I'm still not able to see my local services (where I try to access via the IP of the host given by Tailscale or the magicDNS address). So, progress!

ETA: I also had removed the advertise exit nodes line and restarted the container with the --reset flag. After the warning went away I re-added the exit node option and I get the warning that it is misconfigured again.

[–] pirateMonkey@lemmy.world 1 points 1 week ago

It's true, and I was wondering if that would be the route I have to go. Good to know it has been a positive experience.

[–] pirateMonkey@lemmy.world 1 points 1 week ago (1 children)
[–] pirateMonkey@lemmy.world 1 points 1 week ago

That was an interesting rabbit hole. I'm not sure if it's related or not, but maybe I'll give it a shot once I get my head wrapped around what it really means (though by then they might have developed a fix... and I see how long that's taken so far)

[–] pirateMonkey@lemmy.world 2 points 1 week ago

Misery loves company! Mine is Verizon and there was a setting that was causing me trouble recently, but probably is unrelated to yours (was DNS rebind protection).

[–] pirateMonkey@lemmy.world 2 points 1 week ago (1 children)

No, I thought the routing was to forward the IP from the Tailscale 100.x.x.x subnet(? not sure I'm using that word correctly) to where the resources I want to access are (in my case, my local 192.168 addresses).

[–] pirateMonkey@lemmy.world 2 points 1 week ago

Yes, the machine that is running Docker/Tailscale is serving as an exit node and it hosts all the other services I want to access, which are also in containers.

[–] pirateMonkey@lemmy.world 3 points 1 week ago (2 children)

That's what I was counting on! Guess I just have to look at it as a learning opportunity.

[–] pirateMonkey@lemmy.world 4 points 1 week ago (4 children)

Yeah, I've tried the 100.x.x.x IP and their tailscale URLs, neither of which work.

[–] pirateMonkey@lemmy.world 1 points 1 week ago (2 children)

Yes, it does (been checking with sysctl net.ipv4.ip_forward, but guess it's the same thing). It seems like the issue may be that IPv6 may not be enabled within the container. It's enabled on the host, but the docker logs say ipv6 forwarding is not enabled.

[–] pirateMonkey@lemmy.world 2 points 1 week ago (4 children)

Thanks, I did check that my machine had IP forwarding enabled, and it does. I also ran those lines to create the config file as well, but that didn't change anything. And I do have the lines in my compose file to advertise routes.

 

Back again with another request for help.

I'm trying to set up Tailscale, with the ultimate goal of having a relatively simple way to access all my self hosted services when I'm not at home. My (naive) assumption was that once my device was in I connected to my home network by using my server as an exit node, I could just go to my 196.x.x.x:port address or friendly service.mydomain.xyz url and access things that way. That isn't happening.

I'm running Tailscale in Docker and have Nginx Proxy Manager routing my friendly names to the right place. My services are all run in Docker as well, and most are set up as Proxy Hosts in NPM except one that I added more recently to see if I could access it/if NPM was the issue.

I have set up Tailscale both on my server and phone, I'm able to connect to my server as an exit node, but I don't seem to be able to connect to services on the server. Tailscale is set to use subnets (added TS_ROUTES=192.168.0.0/24 to my compose file), but on my Tailscale Machines tab there is an exclamation mark next to both the Subnets and Exit Node saying the machine is misconfigured and that I need to enable IP forwarding. I double checked, it is enabled (as I understand it, that must be true for docker containers to forward from their 172.x.x.x addresses to 192), but the warning persists and I can't access services (either by the friendly URL, normal IP, tailscale URL, or 100.x.x.x IP).

This is my compose file: services: tailscale-authkey1: image: tailscale/tailscale:latest hostname: myhost environment: - TS_AUTHKEY=xx - TS_STATE_DIR=/var/lib/tailscale - TS_USERSPACE=false - TS_EXTRA_ARGS=--advertise-exit-node,--accept-routes - TS_ROUTES=192.168.0.0/24 volumes: - ts-authkey-test:/var/lib/tailscale - /dev/net/tun:/dev/net/tun cap_add: - NET_ADMIN - SYS_MODULE restart: unless-stopped nginx-authkey-test: image: nginx network_mode: service:tailscale-authkey1

I'm not sure what I should do - I'm seeing this page (https://tailscale.com/kb/1406/quick-guide-subnets) that talks about creating a config file, but that's clearly if you're running on bare metal. I've also looked at their options for running a sidecar (https://tailscale.com/kb/1282/docker), where each service is spun up as a separate TS machine, but that's way more work than I want to do (seems like cloudflare tunnels might be simpler at that point).

Thanks for any help!

0
submitted 1 month ago* (last edited 3 weeks ago) by pirateMonkey@lemmy.world to c/selfhosted@lemmy.world
 

I'm trying to set up a domain to more easily access my services on my home network, using a vanity URL instead of IP:port. With my current setup, my browser is not able to see the server ('we can't connect to the server' at e.g. plex.mydomain.xyz).

I registered the domain through Cloudflare. In Cloudflare, I set up my DNS records (A - mydomain.xyz - content = 192.168.x.x; A - www; CNAME - *), and got my API token. Nginx is running in Docker (as are the services I am trying to access), using the jc21 container and their docker compose template. I used the API token to generate an SSL certificate in NPM with *.mydomain.xyz as the domain, then added a proxy host using the URL mentioned above as the Domain Name, the IP of the server that's running all my containers for the forward hostname/IP, and the appropriate port for forward port. Then in the SSL tab told it to force SSL and HTTP/2.

I'm not sure what I'm doing incorrectly, the only thing I have running that might interfere with the network service is a PiHole, and it appears to be sending the request on. Also tried using localhost (127.0.0.1) to no avail. I've seen some others say they had to restart NPM a few times, so I've tried that as well. Thanks for any help!

*Edit: My router had DNS rebind protection enabled which was blocking the local address. I discovered this by using NSLOOKUP on my home network, where I got a 'No internal type for both IPv4...' error (in Windows command prompt) and outside my home network, where it resolved correctly. Thanks to those who commented, appreciate your time.

view more: next ›