How to share files with syncthing inside a rootless docker container (transmission)

242 Views Asked by At

im getting permission problems when i run the compose file (from portainer) using docker rootless. im pretty sure its something to do with the directories that are set up being given PUID & GUID = 100999... then sychting not have permissions to access them. Not sure what to change in the yml file?

version: '3.7'

services:
  transmission:
    image: linuxserver/transmission
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - TZ=Singapore
      - USERNAME=transmission
      - PASSWORD=transmission_password
    ports:
      - target: 9091
        published: 9091
        protocol: tcp
    volumes:
      - transmission_data:/config
      - /home/betty/Downloads:/downloads

  syncthing:
    image: linuxserver/syncthing
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - TZ=Singapore
      - USERNAME=syncthing
      - PASSWORD=syncthing_password
    ports:
      - 8384:8384
      - 22000:22000/tcp
      - 22000:22000/udp
      - 21027:21027/udp
    restart: unless-stopped
    volumes:
      - syncthing_data:/config
      - /home/betty/Downloads:/downloads

volumes:
  transmission_data:
  syncthing_data:

i was expecting to be able to share the /home/betty/Downloads/ directory via syncthing but i get and error when i try to map to it: Failed to create folder marker: mkdir /home/.stfolder: permission denied

Hope someone can help

0

There are 0 best solutions below