Created
December 16, 2025 08:18
-
-
Save cyqsimon/0ab3f107f022267cb7e5244b233ae713 to your computer and use it in GitHub Desktop.
systemd mount unit using sshfs and password authentication
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [Unit] | |
| Description=SSHFS mount on /mnt/my-data | |
| After=network-online.target | |
| Wants=network-online.target | |
| Before=remote-fs.target | |
| [Mount] | |
| What=user@remote.exmaple.com:/path/to/source | |
| Where=/path/to/dest | |
| Type=fuse.sshfs | |
| Options=allow_other,compression=yes,auto_cache,reconnect,ssh_command=sshpass\040-e\040ssh,port=22 | |
| Environment="SSHPASS=my-password" | |
| [Install] | |
| WantedBy=multi-user.target |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Required packages (EL9):
sshpassandfuse-sshfs.