I want to bind a volume (which is CIFS mounted drive) to my Docker service. I have the following entry in /etc/fstab
file:
100.100.100.100 /media/images cifs username=testuser,password=testpassword,iocharset=utf8,sec=ntlmssp 0 0
I can read and write to /media/images
. When I bind this path to Docker service, it starts up but application (.NET Core) doesn't produce any output which is weird. If I remove the volumes section, it works without any problems and I can see application output.
version: "3.7"
services:
web:
image: myimage:1.2.3
volumes:
- "/media/images:/app/mount/images"
I start the service with docker stack deploy
. There aren't any logs so I can't see what went wrong. The container is up but application isn't working and isn't producing any logs. If I go inside container I can see that volume is mounted and I can read and write to it.
Why doesn't application work when I bind this volume and why are there no logs?