etherai / selfhosted-gateway

Self-hosted Docker native tunneling to localhost. Expose local docker containers to the public Internet via a simple docker compose interface.
https://fractalnetworks.co
GNU Affero General Public License v3.0
1.32k stars 66 forks source link

Links must be recreated after gateway reboot #17

Closed thebalaa closed 9 months ago

thebalaa commented 1 year ago

Two fairly annoying issues with the current implementation:

1) Random port assignments from docker do not persist after reboot. 2) Gateway link container overwrites WireGuard keys in entrypoint

Possible solutions:

1) Generate random port number in create-link.sh and set it explicitly on the gateway's link container so it will persist on reboot 2) Add a check in gateway link's entrypoint for existing WireGuard private key, if it exists do not overwrite it

natecovington commented 1 year ago

I'm interested in helping fix this, without being able to reboot my cloud VPS it seems like this isn't production ready. Seems like a coin toss between your possible solutions, how difficult is something like this to implement?

rockinonthehubnotkansas commented 1 year ago

Has there been any progress made on this issue?

natecovington commented 1 year ago

(FWIW, I started using BoringProxy instead)

rfenouil commented 1 year ago

I'd rather keep using selfhosted-gateway but this issue is concerning indeed... Not using random ports would help ?