mirror of https://github.com/docker/docs.git
Add raw tags back
This commit is contained in:
parent
2635045b51
commit
29af43b84c
|
@ -77,11 +77,13 @@ create and mount a unique Cloudstor volume for each task in a swarm service.
|
||||||
It is possible to use the templatized notation to indicate to Docker Swarm that a unique Cloudstor volume be created and mounted for each replica/task of a service. This may be useful if the tasks write to the same file under the same path which may lead to corruption in case of shared storage. Example:
|
It is possible to use the templatized notation to indicate to Docker Swarm that a unique Cloudstor volume be created and mounted for each replica/task of a service. This may be useful if the tasks write to the same file under the same path which may lead to corruption in case of shared storage. Example:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
{% raw %}
|
||||||
$ docker service create \
|
$ docker service create \
|
||||||
--replicas 5 \
|
--replicas 5 \
|
||||||
--name ping2 \
|
--name ping2 \
|
||||||
--mount type=volume,volume-driver=cloudstor:azure,source={{.Service.Name}}-{{.Task.Slot}}-vol,destination=/mydata \
|
--mount type=volume,volume-driver=cloudstor:azure,source={{.Service.Name}}-{{.Task.Slot}}-vol,destination=/mydata \
|
||||||
alpine ping docker.com
|
alpine ping docker.com
|
||||||
|
{% endraw %}
|
||||||
```
|
```
|
||||||
|
|
||||||
A unique volume is created and mounted for each task participating in the
|
A unique volume is created and mounted for each task participating in the
|
||||||
|
|
Loading…
Reference in New Issue