Add tunnel back service
This commit is contained in:
parent
d7187daadf
commit
59519dd23f
2 changed files with 28 additions and 0 deletions
15
modules/rhizo_base/templates/sshtunnel.service.erb
Normal file
15
modules/rhizo_base/templates/sshtunnel.service.erb
Normal file
|
@ -0,0 +1,15 @@
|
|||
[Unit]
|
||||
Description=SSH Tunnel
|
||||
Requires=sysinit.target system.slice
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/
|
||||
ExecStart=/usr/bin/ssh -v -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -N -c none -i /root/.ssh/bsc_dev <%= @ssh_user %>@<%= @ssh_addr %> -R 220<%= @ssh_p %>:0:22
|
||||
TimeoutStopSec=5
|
||||
Restart=always
|
||||
RestartSec=60
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Add table
Add a link
Reference in a new issue