From e6344f819a01102248a1c1c6504e38a17eaa9b0e Mon Sep 17 00:00:00 2001 From: Daniel Nephin Date: Fri, 9 Oct 2015 11:25:16 -0400 Subject: [PATCH 1/3] Rename yaml reference to compose file reference. Signed-off-by: Daniel Nephin --- docs/completion.md | 2 +- docs/django.md | 2 +- docs/env.md | 2 +- docs/extends.md | 2 +- docs/index.md | 2 +- docs/install.md | 2 +- docs/production.md | 2 +- docs/rails.md | 2 +- docs/reference/overview.md | 2 +- docs/wordpress.md | 2 +- docs/yml.md | 12 ++++++++---- 11 files changed, 18 insertions(+), 14 deletions(-) diff --git a/docs/completion.md b/docs/completion.md index 6e7b42c26..0234f0e92 100644 --- a/docs/completion.md +++ b/docs/completion.md @@ -65,4 +65,4 @@ Enjoy working with Compose faster and with less typos! - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/django.md b/docs/django.md index c5e23e762..e6d31ea01 100644 --- a/docs/django.md +++ b/docs/django.md @@ -164,4 +164,4 @@ In this section, you set up the database connection for Django. - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [YAML file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/env.md b/docs/env.md index 984a340bb..d32a8ba3f 100644 --- a/docs/env.md +++ b/docs/env.md @@ -42,4 +42,4 @@ Fully qualified container name, e.g. `DB_1_NAME=/myapp_web_1/myapp_db_1` - [User guide](index.md) - [Installing Compose](install.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/extends.md b/docs/extends.md index 88fb24a57..e9ea20738 100644 --- a/docs/extends.md +++ b/docs/extends.md @@ -359,4 +359,4 @@ locally-defined bindings taking precedence: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/index.md b/docs/index.md index bff741b6d..a881bfa2c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -54,7 +54,7 @@ Compose has commands for managing the whole lifecycle of your application: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) ## Quick start diff --git a/docs/install.md b/docs/install.md index 654f6421d..66ccfe7c7 100644 --- a/docs/install.md +++ b/docs/install.md @@ -130,4 +130,4 @@ To uninstall Docker Compose if you installed using `pip`: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/production.md b/docs/production.md index 5faa1c696..d18beb7b2 100644 --- a/docs/production.md +++ b/docs/production.md @@ -90,4 +90,4 @@ guide. - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/rails.md b/docs/rails.md index 74c179b59..31d5a2253 100644 --- a/docs/rails.md +++ b/docs/rails.md @@ -129,4 +129,4 @@ That's it. Your app should now be running on port 3000 on your Docker daemon. If - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/reference/overview.md b/docs/reference/overview.md index 1a4c268b3..51bc39b96 100644 --- a/docs/reference/overview.md +++ b/docs/reference/overview.md @@ -81,4 +81,4 @@ it failed. Defaults to 60 seconds. - [User guide](../index.md) - [Installing Compose](../install.md) -- [Yaml file reference](../yml.md) +- [Compose file reference](../yml.md) diff --git a/docs/wordpress.md b/docs/wordpress.md index 8c407e447..b8c8f6b6c 100644 --- a/docs/wordpress.md +++ b/docs/wordpress.md @@ -99,4 +99,4 @@ database containers. If you're using [Docker Machine](https://docs.docker.com/ma - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Yaml file reference](yml.md) +- [Compose file reference](yml.md) diff --git a/docs/yml.md b/docs/yml.md index 209d2f180..1b97d853e 100644 --- a/docs/yml.md +++ b/docs/yml.md @@ -1,15 +1,19 @@ -# docker-compose.yml reference +# Compose file reference + +The compose file is a [YAML](http://yaml.org/) file where all the top level +keys are the name of a service, and the values are the service definition. +The default path for a compose file is `./docker-compose.yml`. Each service defined in `docker-compose.yml` must specify exactly one of `image` or `build`. Other keys are optional, and are analogous to their From 01f44efe0db34541a77db041fdc2093ca849aba9 Mon Sep 17 00:00:00 2001 From: Daniel Nephin Date: Fri, 9 Oct 2015 11:32:26 -0400 Subject: [PATCH 2/3] Re-arrange volume_driver in compose file reference. Signed-off-by: Daniel Nephin --- docs/yml.md | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/yml.md b/docs/yml.md index 1b97d853e..4f10cf5b2 100644 --- a/docs/yml.md +++ b/docs/yml.md @@ -334,7 +334,7 @@ Override the default labeling scheme for each container. - label:user:USER - label:role:ROLE -### volumes +### volumes, volume\_driver Mount paths as volumes, optionally specifying a path on the host machine (`HOST:CONTAINER`), or an access mode (`HOST:CONTAINER:ro`). @@ -348,9 +348,19 @@ You can mount a relative path on the host, which will expand relative to the directory of the Compose configuration file being used. Relative paths should always begin with `.` or `..`. +If you use a volume name (instead of a volume path), you may also specify +a `volume_driver`. + + volume_driver: mydriver + + > Note: No path expansion will be done if you have also specified a > `volume_driver`. +See [Docker Volumes](https://docs.docker.com/userguide/dockervolumes/) and +[Volume Plugins](https://docs.docker.com/extend/plugins_volume/) for more +information. + ### volumes_from Mount all of the volumes from another service or container, optionally @@ -361,7 +371,7 @@ specifying read-only access(``ro``) or read-write(``rw``). - container_name - service_name:rw -### cpu\_shares, cpuset, domainname, entrypoint, hostname, ipc, mac\_address, mem\_limit, memswap\_limit, privileged, read\_only, restart, stdin\_open, tty, user, volume\_driver, working\_dir +### cpu\_shares, cpuset, domainname, entrypoint, hostname, ipc, mac\_address, mem\_limit, memswap\_limit, privileged, read\_only, restart, stdin\_open, tty, user, working\_dir Each of these is a single value, analogous to its [docker run](https://docs.docker.com/reference/run/) counterpart. @@ -388,8 +398,6 @@ Each of these is a single value, analogous to its stdin_open: true tty: true - volume_driver: mydriver - ## Variable substitution Your configuration options can contain environment variables. Compose uses the From fbfbe60246de0a86f84da859c07ee1a64e32ea05 Mon Sep 17 00:00:00 2001 From: Daniel Nephin Date: Tue, 13 Oct 2015 15:23:27 -0400 Subject: [PATCH 3/3] Rename yml.md to compose-file.md and add an alias for the old url. Signed-off-by: Daniel Nephin --- docs/completion.md | 2 +- docs/{yml.md => compose-file.md} | 1 + docs/django.md | 2 +- docs/env.md | 2 +- docs/extends.md | 2 +- docs/index.md | 4 ++-- docs/install.md | 2 +- docs/production.md | 2 +- docs/rails.md | 2 +- docs/reference/overview.md | 2 +- docs/wordpress.md | 2 +- 11 files changed, 12 insertions(+), 11 deletions(-) rename docs/{yml.md => compose-file.md} (99%) diff --git a/docs/completion.md b/docs/completion.md index 0234f0e92..bc8bedc96 100644 --- a/docs/completion.md +++ b/docs/completion.md @@ -65,4 +65,4 @@ Enjoy working with Compose faster and with less typos! - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/yml.md b/docs/compose-file.md similarity index 99% rename from docs/yml.md rename to docs/compose-file.md index 4f10cf5b2..725130f78 100644 --- a/docs/yml.md +++ b/docs/compose-file.md @@ -3,6 +3,7 @@ title = "Compose file reference" description = "Compose file reference" keywords = ["fig, composition, compose, docker"] +aliases = ["/compose/yml"] [menu.main] parent="smn_compose_ref" +++ diff --git a/docs/django.md b/docs/django.md index e6d31ea01..c7ebf58bf 100644 --- a/docs/django.md +++ b/docs/django.md @@ -164,4 +164,4 @@ In this section, you set up the database connection for Django. - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/env.md b/docs/env.md index d32a8ba3f..8f3cc3ccb 100644 --- a/docs/env.md +++ b/docs/env.md @@ -42,4 +42,4 @@ Fully qualified container name, e.g. `DB_1_NAME=/myapp_web_1/myapp_db_1` - [User guide](index.md) - [Installing Compose](install.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/extends.md b/docs/extends.md index e9ea20738..d88ce61c5 100644 --- a/docs/extends.md +++ b/docs/extends.md @@ -359,4 +359,4 @@ locally-defined bindings taking precedence: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/index.md b/docs/index.md index a881bfa2c..2e10e0801 100644 --- a/docs/index.md +++ b/docs/index.md @@ -54,7 +54,7 @@ Compose has commands for managing the whole lifecycle of your application: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) ## Quick start @@ -196,7 +196,7 @@ At this point, you have seen the basics of how Compose works. - Next, try the quick start guide for [Django](django.md), [Rails](rails.md), or [WordPress](wordpress.md). - See the reference guides for complete details on the [commands](./reference/index.md), the - [configuration file](yml.md) and [environment variables](env.md). + [configuration file](compose-file.md) and [environment variables](env.md). ## Release Notes diff --git a/docs/install.md b/docs/install.md index 66ccfe7c7..2d4d6cadb 100644 --- a/docs/install.md +++ b/docs/install.md @@ -130,4 +130,4 @@ To uninstall Docker Compose if you installed using `pip`: - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/production.md b/docs/production.md index d18beb7b2..8793f9277 100644 --- a/docs/production.md +++ b/docs/production.md @@ -90,4 +90,4 @@ guide. - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/rails.md b/docs/rails.md index 31d5a2253..a33cac26e 100644 --- a/docs/rails.md +++ b/docs/rails.md @@ -129,4 +129,4 @@ That's it. Your app should now be running on port 3000 on your Docker daemon. If - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md) diff --git a/docs/reference/overview.md b/docs/reference/overview.md index 51bc39b96..3f589a9de 100644 --- a/docs/reference/overview.md +++ b/docs/reference/overview.md @@ -81,4 +81,4 @@ it failed. Defaults to 60 seconds. - [User guide](../index.md) - [Installing Compose](../install.md) -- [Compose file reference](../yml.md) +- [Compose file reference](../compose-file.md) diff --git a/docs/wordpress.md b/docs/wordpress.md index b8c8f6b6c..8c1f5b0ac 100644 --- a/docs/wordpress.md +++ b/docs/wordpress.md @@ -99,4 +99,4 @@ database containers. If you're using [Docker Machine](https://docs.docker.com/ma - [Get started with Rails](rails.md) - [Get started with WordPress](wordpress.md) - [Command line reference](./reference/index.md) -- [Compose file reference](yml.md) +- [Compose file reference](compose-file.md)