Skip to content

Instantly share code, notes, and snippets.

@fabiolimace
Forked from klutchell/s3fs.service
Created May 17, 2024 09:33
Show Gist options
  • Save fabiolimace/9dd63a21611e21dcb8811ef9f86f0041 to your computer and use it in GitHub Desktop.
Save fabiolimace/9dd63a21611e21dcb8811ef9f86f0041 to your computer and use it in GitHub Desktop.
systemd unit file for s3fs fuse auto-mount
Description=S3FS FUSE mount
Documentation=https://github.com/s3fs-fuse/s3fs-fuse
Wants=network-online.target
After=network-online.target
AssertPathIsDirectory=/mnt/s3fs
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/usr/bin/s3fs mybucket:/bucketdir /mnt/s3fs -o url=https://nyc3.digitaloceanspaces.com -o use_cache=/tmp -o allow_other -o use_path_request_style -o uid=1000 -o gid=1000
ExecStop=/bin/fusermount -u /mnt/s3fs
[Install]
WantedBy=default.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment