lsshfs mounts a remote directory from a single host in your lssh inventory.
It reuses the same host selection and SSH config flow as lssh, but exposes the remote path through a local mount backend that depends on the client OS.
- Linux clients use
FUSE - macOS clients use
NFS - Windows is not supported in
0.9.0
The command runs in the background by default and automatically unmounts when the SSH connection is lost.
$ lsshfs --help
NAME:
lsshfs - Single-host SSH mount command with OS-specific local mount backends.
USAGE:
lsshfs [options] [host:]remote_path mountpoint
OPTIONS:
--host servername, -H servername connect servername.
--file filepath, -F filepath config filepath. (default: "/Users/blacknon/.lssh.conf")
--generate-lssh-conf ~/.ssh/config print generated lssh config from OpenSSH config to stdout (~/.ssh/config by default).
--debug enable debug logging for lsshfs and go-sshlib.
--rw mount as read-write (current default behavior).
--unmount unmount the specified mountpoint and stop the background process.
--list-mounts list active lsshfs mount records.
--foreground run in the foreground for debugging and tests.
--list, -l print server list from config.
--help, -h print this help
--enable-control-master temporarily enable ControlMaster for this command execution
--disable-control-master temporarily disable ControlMaster for this command execution
--version, -v print the version
VERSION:
lssh-suite 0.9.0 (beta/transfer)
USAGE:
# mount a remote path from the selected host
lsshfs /srv/data ~/mnt/data
# mount a remote path from the named inventory host
lsshfs @app:/srv/data ~/mnt/data
# unmount
lsshfs --unmount ~/mnt/data
lsshfs resolves exactly one target host, then mounts one remote directory to one local mountpoint.
You can specify the host explicitly with @host:/path, use -H, or let the TUI picker choose the host for you.
lsshfs @web01:/var/www ./mnt/web01
lsshfs -H web01 /var/www ./mnt/web01
lsshfs --rw @web01:/srv/app ./mnt/appMounts are recorded locally so you can list them later or unmount by mountpoint. This is the easiest way to clean up background sessions after a long-lived mount.
lsshfs --unmount ./mnt/app
lsshfs --list-mountslsshfssupports only one host at a time.@host:/pathis the preferred remote path format, buthost:/pathis still accepted for compatibility.- On macOS, the local mount is created with
mount_nfs. - On Windows,
lsshfsis not supported in0.9.0. - The default config search order is
~/.lssh.toml,~/.lssh.yaml,~/.lssh.yml, then~/.lssh.conf.