Code Monkey home page Code Monkey logo

Comments (12)

miversen33 avatar miversen33 commented on June 10, 2024 3

I'm running into the same issue. I am using a modified version of the docker compose configuration

version: "3.7"
services:
    navidrome:
      image: deluan/navidrome:latest
      container_name: navidrome
      hostname: navidrome
      user: 1000:1000
      ports:
        - 4533:4533
      restart: unless-stopped
      environment:
        ND_SCANSCHEDULE: 1h
        ND_LOGLEVEL: info
        ND_SESSIONTIMEOUT: 24h
      volumes:
        - navidrome_data:/data
        - /mnt/Media_Store/Music:/music
volumes:
  navidrome_data:

I would expect this to work as docker is simply creating an empty volume and giving it to the container. I suspect the issue is that I am declaring a user (as specified by the config).

Edit: Removing the user tag from the config got this up and running. So it is indeed an issue that the user (whatever uid used) does not have write access to a volume given by docker compose. I could likely fix this via some modifications to the volume in the docker compose yaml but honestly, just removing the tag is easier

from navidrome.

codenamek83 avatar codenamek83 commented on June 10, 2024 2

What a coincidence! I was looking to move the cache directory to a different location and ran into the same issue.

from navidrome.

codenamek83 avatar codenamek83 commented on June 10, 2024 2

The cache directory is in your data folder. Where the the data folder is depends on your Installation method and on your configuration. Navidrome has to have full read/write permissions to the data folder (to be able to write to the database and create cachr files)

Is it possible to move the Cache directory to a different path outside the Data directory?

from navidrome.

goppinath avatar goppinath commented on June 10, 2024 2

I'm running into the same issue. I am using a modified version of the docker compose configuration

version: "3.7"
services:
    navidrome:
      image: deluan/navidrome:latest
      container_name: navidrome
      hostname: navidrome
      user: 1000:1000
      ports:
        - 4533:4533
      restart: unless-stopped
      environment:
        ND_SCANSCHEDULE: 1h
        ND_LOGLEVEL: info
        ND_SESSIONTIMEOUT: 24h
      volumes:
        - navidrome_data:/data
        - /mnt/Media_Store/Music:/music
volumes:
  navidrome_data:

I would expect this to work as docker is simply creating an empty volume and giving it to the container. I suspect the issue is that I am declaring a user (as specified by the config).

Edit: Removing the user tag from the config got this up and running. So it is indeed an issue that the user (whatever uid used) does not have write access to a volume given by docker compose. I could likely fix this via some modifications to the volume in the docker compose yaml but honestly, just removing the tag is easier

Yes, removing the user: 1000:1000 property resolved the issue.

from navidrome.

metalheim avatar metalheim commented on June 10, 2024

The cache directory is in your data folder. Where the the data folder is depends on your Installation method and on your configuration.
Navidrome has to have full read/write permissions to the data folder (to be able to write to the database and create cachr files)

from navidrome.

conartist6 avatar conartist6 commented on June 10, 2024

I'd appreciate that too as I'm running this on a raspberry PI, and I like to keep cache stuff on a proper tmpfs so that my SD card can live a long and healthy life

from navidrome.

deluan avatar deluan commented on June 10, 2024

Is it possible to move the Cache directory to a different path outside the Data directory?

Yes it is. Look for CacheFolder in the documentation.

from navidrome.

codenamek83 avatar codenamek83 commented on June 10, 2024

Is it possible to move the Cache directory to a different path outside the Data directory?

Yes it is. Look for CacheFolder in the documentation.

Thank you for the response. I've mounted three volumes (bind-mount) to the container, and I'm encountering a 'path cache mkdir cache: permission denied' issue. The user has full read and write access to the mount from the container. I removed the ND_CACHEFOLDER variable and tried this manually to ensure that it's not a permission problem.

Config:

`volumes:

  • /path/to/navidrome01:/data
  • /path/to/navidrome01-cache:/cache
  • /path/to/music:/music:ro
    environment:
  • ND_CACHEFOLDER="./cache"`

PS: I also tried ND_CACHEFOLDER="cache". ND_CACHEFOLDER="/cache"`.

from navidrome.

deluan avatar deluan commented on June 10, 2024

In your case, path must be /cache (same as the volume)

Can you post your full docker-compose.yml? What is your host OS? If it is Linux can you check permissions of the folder by doing a ls -ld /path/to/navidrome01-cache and post here, please?

from navidrome.

codenamek83 avatar codenamek83 commented on June 10, 2024

In your case, path must be /cache (same as the volume)

Can you post your full docker-compose.yml? What is your host OS? If it is Linux can you check permissions of the folder by doing a ls -ld /path/to/navidrome01-cache and post here, please?

`version: "3.8"

services:
navidrome01:
user: 1000:1000
image: deluan/navidrome:0.50.2
container_name: navidrome01
hostname: navidrome01
networks:
- navidrome01
ports:
- 8106:4533
volumes:
- /data/homefs/bindmount/navidrome01:/data
- /data/homefs/bindmount-cache/navidrome01:/cache
- /data/homefs/entertainment/music:/music:ro
environment:
- TZ=Asia/Singapore
- ND_LOGLEVEL=info
- ND_DEFAULTTHEME=spotify-ish
- ND_IMAGECACHESIZE=5GB
- ND_TRANSCODINGCACHESIZE=5GB
- ND_CACHEFOLDER="/cache"
- ND_ENABLEDOWNLOADS=false
- ND_ENABLEUSEREDITING=true
- ND_SCANSCHEDULE=1h
- ND_SESSIONTIMEOUT=24h
- ND_PLAYLISTSPATH=playlists
- ND_COVERARTPRIORITY=cover.*
- ND_PASSWORDENCRYPTIONKEY=
- ND_LASTFM_ENABLED=true
- ND_LASTFM_LANGUAGE=en
- ND_LASTFM_APIKEY=
- ND_LASTFM_SECRET=
- ND_SPOTIFY_ID=
- ND_SPOTIFY_SECRET=
- ND_UIWELCOMEMESSAGE="Own your music, do not rent it!"
restart: unless-stopped
security_opt:
- no-new-privileges:true

networks:
navidrome01:
name: navidrome01
driver: bridge`

What is your host OS?
Debian GNU/Linux 11 (bullseye) aarch64 (Raspberry)

f it is Linux can you check permissions of the folder by doing a ls -ld /path/to/navidrome01-cache and post here, please?
drwxr-xr-x 2 adm-tom adm-tom 4096 Jan 4 02:34 bindmount-cache/

from navidrome.

sastromo avatar sastromo commented on June 10, 2024

Im also having this problem after I start the container.
Any possible solutions?? Im kinda lost :)

Screenshot_3

from navidrome.

lukebouch avatar lukebouch commented on June 10, 2024

Yes, removing the user: 1000:1000 property resolved the issue.

Why does that fix it?

from navidrome.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.