docker-borg icon indicating copy to clipboard operation
docker-borg copied to clipboard

Using --mount instead of -v for backup dirs

Open cortlieb opened this issue 1 year ago • 2 comments

Hi pschiffe, I'm using your docker-image since a while and it works great!

I have one question (actually two, but I will post the 2nd question separately 😊). I want to use a directory that has a colon in its name (time when directory was created). The -v flag fails since it expects only one colon to separate host- and container-path. Would it be possible to use your image with --mount type=bind,source=<host-path-with-colon>,destination=/borg/data/<name>,readonly instead of - v <host-path>:/borg/data/<name>:ro ?

cortlieb avatar Sep 24 '24 07:09 cortlieb

Hi @cortlieb :wave:

I mean, probably yes, it should work, feel free to try it. I found the following stack overflow and moby issue related to this:

https://stackoverflow.com/questions/46335325/cannot-mount-volume-in-docker-container-when-directory-name-contains-colon

https://github.com/moby/moby/issues/8604

They say that also a symlink may help.

pschiffe avatar Sep 24 '24 09:09 pschiffe

Ok, yes, sure I can do it on my own, just thought you might have already some experience with that approach.

cortlieb avatar Sep 24 '24 12:09 cortlieb