Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

inotify doesn't work on NFS volumes #7

Open
steven-ellis opened this issue Apr 9, 2021 · 3 comments
Open

inotify doesn't work on NFS volumes #7

steven-ellis opened this issue Apr 9, 2021 · 3 comments

Comments

@steven-ellis
Copy link

Need a way to force a refresh as inotify doesn't work if we're using NFS to store the media

eg

podman volume create --opt type=nfs --opt o=ro --opt device=mediaserver:/mnt/Videos Videos

podman run -d --name minidlna \
  --net=host \
  -v Video:/opt/Videos \
  -v /var/cache/minidlna:/var/cache/minidlna:Z \
  geekduck/minidlna

Is there any way to get a refresh without reloading/rebuilding the DB. I'm running with a persistent Cache and DB. Start/Stop doesn't cause a re-scan

podman stop minidlna
podman start minidlna

@korentzari
Copy link

korentzari commented Dec 8, 2021

You can change /usr/bin/entrypoint.sh with
exec /usr/sbin/minidlnad -r -S
For force rescan each start docker

@steven-ellis
Copy link
Author

Thanks. I've already created a custom version of entrypoint.sh

#!/bin/sh

if [ -e /run/minidlna/minidlna.pid ]; then
    rm /run/minidlna/minidlna.pid
fi

exec /usr/sbin/minidlnad -r -S

And then Run via

podman run -d --name minidlna \
  --net=host \
  -v VideoVol:/opt/Videos \
  -v Audio:/opt/Music \
  -v /root/containers/minidlna/cache:/var/cache/minidlna:Z \
  --mount type=bind,src=/root/containers/minidlna/entrypoint.sh,target=/usr/bin/entrypoint.sh,relabel=shared \
  geekduck/minidlna

To force a rescan podman restart minidlna

@steven-ellis
Copy link
Author

Having an API option to force a rescan rather than restarting the pod would be very useful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants