Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [Unit]
- Description=Keeps a tunnel to 'remote.example.com' open
- After=network.target
- [Service]
- User=autossh
- # -p [PORT]
- # -l [user]
- # -M 0 --> no monitoring
- # -N Just open the connection and do nothing (not interactive)
- # LOCALPORT:IP_ON_EXAMPLE_COM:PORT_ON_EXAMPLE_COM
- #AUTOSSH_GATETIME
- ExecStart=/usr/bin/autossh -M 0 -N -q -o "ServerAliveInterval 60" -o "ServerAliveCountMax 3" -p 22 -l autossh remote.example.com -L 7474:127.0.0.1:7474 -i /home/autossh/.ssh/id_rsa
- [Install]
- WantedBy=multi-user.target
Add Comment
Please, Sign In to add comment