I am trying to use the Docker SDK for Python to create a service.
I need some mounts of type "bind" but I don't know how to specify this using the client.services.create
command.
It only accepts a list of strings of format source:target:options
where options can only be rw
or ro
.
The created mounts are therefore all of type "volume".
The result I am trying to achieve should be similar with what I can get using the Docker CLI with
docker service create \
...
--mount type=bind,src=/host/path,dst=/container/path
Is that possible? If so: how?