Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #/lib/systemd/system/autossh.service
- [Unit]
- Description=Auto Reverse SSH
- Requires=systemd-networkd-wait-online.service
- After=systemd-networkd-wait-online.service
- [Service]
- Type=forking
- ExecStart=/usr/bin/autossh -M 0 -f -N -R 2255:localhost:22 user@domain -g -o ServerAliveInterval=60 -o ServerAliveCountMax=3 -o ExitOnForwardFailure=yes
- [Install]
- WantedBy=multi-user.target
- sudo systemctl status autossh.service
- ssh -R 2255:localhost:22 user@domain
- /usr/bin/autossh -M 0 -f -N -R 2255:localhost:22 user@domain -g -o ServerAliveInterval=60 -o ServerAliveCountMax=3
Add Comment
Please, Sign In to add comment