mirror of https://github.com/docker/docs.git
Address requested changes
This commit is contained in:
parent
12b603c577
commit
0411064829
|
@ -14,8 +14,8 @@ mode tasks and regular Docker containers can use a volume created with
|
|||
Cloudstor to mount a persistent data volume. In Docker for AWS, Cloudstor has
|
||||
two `backing` options:
|
||||
|
||||
- `relocatable` data volumes which are backed by EBS.
|
||||
- `shared` data volumes which are backed by EFS.
|
||||
- `relocatable` data volumes are backed by EBS.
|
||||
- `shared` data volumes are backed by EFS.
|
||||
|
||||
When you use the Docker CLI to create a swarm service along with the persistent
|
||||
volumes used by the service tasks, you can create three different types of
|
||||
|
@ -132,11 +132,13 @@ The only option available for EFS is `perfmode`. You can set `perfmode` to
|
|||
`maxio` for high IO throughput:
|
||||
|
||||
```bash
|
||||
{% raw %}
|
||||
$ docker service create \
|
||||
--replicas 5 \
|
||||
--name ping3 \
|
||||
--mount type=volume,volume-driver=cloudstor:aws,source={{.Service.Name}}-{{.Task.Slot}}-vol5,destination=/mydata,volume-opt=perfmode=maxio \
|
||||
alpine ping docker.com
|
||||
{% endraw %}
|
||||
```
|
||||
|
||||
You can also create `shared` Cloudstor volumes using the
|
||||
|
@ -163,11 +165,13 @@ the following volume options are available:
|
|||
Example usage:
|
||||
|
||||
```bash
|
||||
{% raw %}
|
||||
$ docker service create \
|
||||
--replicas 5 \
|
||||
--name ping3 \
|
||||
--mount type=volume,volume-driver=cloudstor:aws,source={{.Service.Name}}-{{.Task.Slot}}-vol,destination=/mydata,volume-opt=backing=local,volume-opt=size=25,volume-opt=ebstype=gp2 \
|
||||
alpine ping docker.com
|
||||
{% endraw %}
|
||||
```
|
||||
|
||||
The above example creates and mounts a distinct Cloudstor volume backed by 25 GB EBS
|
||||
|
@ -186,7 +190,6 @@ IOPs is absolutely necessary.
|
|||
You can also create EBS backed volumes using the `docker volume create` CLI:
|
||||
|
||||
```bash
|
||||
{% raw %}
|
||||
$ docker volume create \
|
||||
-d "cloudstor:aws" \
|
||||
--opt ebstype=io1 \
|
||||
|
@ -194,7 +197,6 @@ $ docker volume create \
|
|||
--opt iops=1000 \
|
||||
--opt backing=relocatable \
|
||||
mylocalvol1
|
||||
{% endraw %}
|
||||
```
|
||||
|
||||
Sharing the same `relocatable` Cloudstor volume across multiple tasks of a
|
||||
|
@ -209,11 +211,13 @@ you already have too many EBS volumes or want to reduce the amount of time it
|
|||
takes to transfer volume data across availability zones.
|
||||
|
||||
```bash
|
||||
{% raw %}
|
||||
$ docker service create \
|
||||
--replicas 5 \
|
||||
--name ping2 \
|
||||
--mount type=volume,volume-driver=cloudstor:aws,source={{.Service.Name}}-{{.Task.Slot}}-vol,destination=/mydata \
|
||||
alpine ping docker.com
|
||||
{% endraw %}
|
||||
```
|
||||
|
||||
Here, each task has mounts its own volume at `/mydata/` and the files under that
|
||||
|
|
Loading…
Reference in New Issue