8 releases

0.3.4 May 21, 2024
0.3.3 Apr 19, 2022
0.3.2 Feb 2, 2022
0.3.1 Oct 28, 2021
0.1.0 Aug 7, 2021

#32 in #health

Download history 4/week @ 2024-02-24 1/week @ 2024-03-09 32/week @ 2024-03-30 9/week @ 2024-04-06 137/week @ 2024-05-18 8/week @ 2024-05-25

145 downloads per month

GPL-3.0-or-later OR copyleft-next-0.3.1

264 lines


This project is abandoned; use something like tailscale instead.

multi-tunnel allows starting and managing SSH tunnels in a straightforward manner. Create a TOML configuration file, start the service and you're all set. If you change the configuration, send a SIGHUP (aka systemctl reload) and it'll start/stop tunnels as necessary.

Tunnels that get stopped or killed for any reason will be restarted after a 5-second delay. Every 60s it will SSH into the host to run health checks to make sure the ports are accessible over HTTP. Note that curl must be installed on the remote host.


For example, to tunnel httpd running on port 8080 to a remote server on 8000 and nginx running on port 8081 to 8001 on the remote server:

connection = "remote.host"

local = 8080
remote = 8000

local = 8081
remote = 8001

The name is arbitrary and is used only for log entries.


A Prometheus endpoint to scrape is available at


multi-tunnel is dual licensed under the GPL v3 or later OR copyleft-next 0.3.1, see LICENSES/.


~267K SLoC