samba
samba copied to clipboard
Combining Samba and enfs
Since i can not install encfs via macports on MacOS catalina anymore see https://trac.macports.org/ticket/59316 - i was hoping to use an encfs docker container e.g. https://github.com/twhtanghk/encfs. Then I'd have to make the unencrypted content available e.g. via Samba which might be possible using this docker solution. But how would i combine the two so that i can access and enfs encrypted file system on a USB stick?
I use samba+cryfs to do something similar, idk about the usb situation. I figure if the usb is mounted on the host, you can just create a volume there. Maybe you also need to pass the usb device in as well.
cryfs:
container_name: cryfs
image: edyounis/cryfs
restart: unless-stopped
cap_add:
- SYS_ADMIN
devices:
- "/dev/fuse:/dev/fuse"
environment:
- 'PASSWD=badpass'
- 'MOUNT_OPTIONS=nonempty,allow_other,noatime,nodiratime'
volumes:
- "/path/to/encrypted:/encrypted"
- "/path/to/place/decrypted:/decrypted:shared"
samba:
container_name: samba
image: dperson/samba
restart: always
mem_limit: 512m
environment:
- 'USERID=1000'
- 'GROUPID=1000'
- 'USER...'
- 'SHARE...'
ports:
- '139:139'
- '445:445'
volumes:
- "/path/to/place/decrypted:/decrypted:shared" # <--- use this location to create shares