Sunday, June 23, 2019

autossh systemd startup

/etc/systemd/system/autossh.service

################################################################################
#
#
#
################################################################################
[Unit]

Description=AutoSSH tunnel service for AWX C2
After=network-online.target

[Service]
Type=simple
User=<username>
Environment="AUTOSSH_GATETIME=0"
Environment="AUTOSSH_LOGLEVEL=7"
ExecStart=/usr/bin/autossh -M 0 -N -T -q -o "ServerAliveInterval 30" -o "ServerAliveCountMax 3" awslnx001

[Install]
WantedBy=multi-user.target


config:

Host rlgway
    Hostname x.x.x.x
    User <username?
    Port 22
    IdentityFile ~/.ssh/<file>
    GSSAPIAuthentication no
    GSSAPIDelegateCredentials no
    RemoteForward 2223 localhost:22

Current Audible Reading List

Title You Never Forget Your First: A Biography of George Washington A Self-Made Man: The Politica...