Skip to content

Instantly share code, notes, and snippets.

@Gnnng
Created October 26, 2017 08:42
Show Gist options
  • Save Gnnng/c8d3f8fe8264a62ab141df47759068c6 to your computer and use it in GitHub Desktop.
Save Gnnng/c8d3f8fe8264a62ab141df47759068c6 to your computer and use it in GitHub Desktop.
A systemd service template for reverse proxy using autossh
[Unit]
Description=autossh daemon for remote-server
After=network.target
[Service]
User=gongdeli
ExecStart=/usr/bin/autossh -NR 62222:localhost:2222 remote-server
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment