Closed bleketux closed 6 years ago
solved by doing git clone the repo then rerun above command.
@bleketux Can you clarify? I am seeing same issue
dulanic@mediaserver:/etc$ sudo docker run -d -v $(pwd)/Caddyfile:/etc/Caddyfile -v $HOME/.caddy:/root/.caddy -p 80:80 -p 443:443 abiosoft/caddy
3e5e8002288f67d581973676fdde576e98fc5ee13a8730451d771d4407ec7495
docker: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process caused "process_linux.go:402: container init caused \"rootfs_linux.go:58: mounting \\\"/etc/Caddyfile\\\" to rootfs \\\"/var/lib/docker/overlay2/34f08787b923aaefef3c3ca0cde88a61b805888ee9703317ba56727adb3c3d37/merged\\\" at \\\"/var/lib/docker/overlay2/34f08787b923aaefef3c3ca0cde88a61b805888ee9703317ba56727adb3c3d37/merged/etc/Caddyfile\\\" caused \\\"not a directory\\\"\"": unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type.
@Dulanic , last time I have this problem was because I have wrong filename on Caddyfile. My filename was CaddyFile, while it should be Caddyfile. Well, actually it depend on how you adjust the command parameters. But I'm not sure you have the same problem as mine.
I try to run caddy for the firsttime using below command as mention on readme.md: $ docker run -d -v $(pwd)/Caddyfile:/etc/Caddyfile -p 80:80 -p 443:443 abiosoft/caddy
but then the following error occured: C:\Program Files\Docker Toolbox\docker.exe: Error response from daemon: OCI runtime create failed: container_linux.go:348: starting container process caused "process_linux.go:402: container init caused \"rootfs_linux.go:58: mounting \\"/c/Users/bleketux/docker/Caddyfile\\" to rootfs \\"/mnt/sda1/var/lib/docker/aufs/mnt/3de93b6f1fc4559dacfbd9ee2268c6591feda6a3e2c7f9415b8a6db963672006\\" at \\"/mnt/sda1/var/lib/docker/aufs/mnt/3de93b6f1fc4559dacfbd9ee2268c6591feda6a3e2c7f9415b8a6db963672006/etc/Caddyfile\\" caused \\"not a directory\\"\"": unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type.
any suggestions?