Create SSH VPN over PPP

Create SSH VPN over PPP
Photo by Petter Lagson / Unsplash

sudo vi /lib/systemd/system/pppd.service

[Unit]
Description=PPP over Serial link
After=network.target

[Service]
ExecStart=/usr/sbin/pppd nodetach noauth silent nodeflate pty "/usr/bin/ssh root@<your_remote_server_ip> /usr/sbin/pppd nodetach notty noauth" ipparam vpn 172.18.8.1:172.18.8.2
Restart=on-failure

[Install]
WantedBy=multi-user.target

sudo systemctl reload pppd