From d264ca4f82b1b5c162f0f8bd0552fca114d3263b Mon Sep 17 00:00:00 2001 From: Erin Sims Date: Sat, 1 Oct 2022 04:49:37 -0400 Subject: [PATCH] working on changes, and debugging --- playbooks/sshfs.service.j2 | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/playbooks/sshfs.service.j2 b/playbooks/sshfs.service.j2 index 1b6215b..e7813e9 100644 --- a/playbooks/sshfs.service.j2 +++ b/playbooks/sshfs.service.j2 @@ -2,18 +2,15 @@ Description=SSHFS Daemon After=network-online.target Wants=network-online.target -StartLimitIntervalSec=300 -StartLimitBurst=10 [Install] WantedBy=default.target -[Service] -Type=exec -User=sshfs -Group=www-data -ExecStart=/usr/bin/sshfs -p {{sshfsport }} -o rw,allow_other,idmap=user,uid=1000,gid=1000,ServerAliveInterval=10,ServerAliveCountMax=1,_netdev {{ [username,'@',hostname,':',remotepath,item,'/',' ',localpath,item,'/' ]|join() }} -ExecStop=/usr/bin/umount "{{[ localpath,item,'/']|join() }}" -RestartSec=20 +[Mount] +Type=fuse.sshfs +What={{ [username,'@',hostname,':',remotepath,item,'/' ]|join() }} +Where={{[ localpath,item,'/']|join() }} +Options=_netdev,reconnect,ServerAliveInterval=30,ServerAliveCountMax=5,x-systemd.automount +TimeoutSec=120 Restart=on-failure