John Mulhausen
9a39f03cb7
Merge pull request #595 from ankon/patch-1
...
Use curl's -o to specify the output
2016-11-16 11:42:48 -08:00
John Mulhausen
698f8d26f4
Merge pull request #593 from jefferybradberry/patch-1
...
There are two differences
2016-11-16 11:34:18 -08:00
Victoria Bialas
1249d35fca
added troubleshooting info about shared drives/files and volume mounting
...
added more changes
updated per Nathan's comments on properly documenting directories formats for all platforms
incorporated Daniel's review comments, and added a clarification re: users' dir
copyedits
Signed-off-by: Victoria Bialas <victoria.bialas@docker.com>
2016-11-16 11:02:04 -08:00
Andreas Kohn
f07aa9e026
Use curl's -o to specify the output
...
This makes it easier to fix up the command by just prepending a `sudo` if something goes wrong.
2016-11-16 13:05:30 +01:00
Jeffery Bradberry
b68ad3aced
There are two differences
...
Add missing word.
2016-11-16 04:43:22 -05:00
Kevin Conboy
c4d4069279
Update wordpress.md
...
capital_P_dangit()
2016-11-15 09:47:54 -07:00
David Williamson
186dfbb336
Update compose example to work better with swarm
...
Update the compose example:
* Remove the `links` directive. This allows swarm to distribute containers across available nodes. (with the `links` directive, swarm will be forced to run both containers on the same node.) Note that the `depends_on` directive is sufficient to ensure correct container start up sequence.
* Use a docker volume instead of bind mounting a local directory.
* Give docker-compose commands for shutting down the Wordpress app, showing how to preserve or remove the persisted data in the volume.
Verified proposed change works correctly in both a swarm and a non-swarm environment.
2016-11-11 14:24:39 -08:00
Jonas Friedmann
4d83c1bb08
Add missing dollar-sign / consistent shell style ( #426 )
...
* Add missing dollar-sign
* Remove dollar-sign for single commands without output
2016-11-10 14:54:49 -08:00
Gaetan
2ea564166d
fix type of keywords entry in frontmatter (in /compose/ dir) ( #481 )
...
keywords should be a string, not an array containing one string
Signed-off-by: Gaetan de Villele <gdevillele@gmail.com>
2016-11-07 13:18:56 -08:00
John Mulhausen
949a89e6ea
Merge pull request #152 from mstanleyjones/redirect_from
...
Change 'alias:' to 'redirect_from:' so aliases work again
2016-11-04 17:34:27 -07:00
Misty Stanley-Jones
f4b0ec85ff
Merge pull request #339 from dave-pollock/patch-1
...
Update swarm.md
2016-11-04 17:11:40 -07:00
Misty Stanley-Jones
eb5c8670bc
Change instances of alias: to redirect_from:
...
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2016-11-04 17:07:02 -07:00
John Mulhausen
558314bf56
Converges titles to imperative-form, front-matter based, and sentence-case ( #438 )
...
Multiple title fixes, consistency fixes, convergence into metadata-based titles.
2016-11-04 15:38:40 -07:00
Misty Stanley-Jones
ac0cef5d0f
Merging master into vnext-compose
...
includes conflict resolution
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2016-11-04 15:25:34 -07:00
Misty Stanley-Jones
1a193d749b
Revert "Merge pull request #437 from gdevillele/fix_keywords_format"
...
This reverts commit 13ddc1350e
, reversing
changes made to 7a11f05943
.
2016-11-04 13:33:29 -07:00
Misty Stanley-Jones
33d3d067d0
Revert "fix some frontmatter keywords values"
2016-11-04 13:30:04 -07:00
Misty Stanley-Jones
0827ba283c
Revert "fix frontmatter keywords values in compose/reference/ files"
2016-11-04 13:28:43 -07:00
Misty Stanley-Jones
13ddc1350e
Merge pull request #437 from gdevillele/fix_keywords_format
...
fix some frontmatter keywords values
2016-11-04 10:50:53 -07:00
Gaetan
8bb4d6226a
fix more frontmatter keywords values ( #439 )
...
* fix format of frontmatter keyword entry in some .md files
Signed-off-by: Gaetan de Villele <gdevillele@gmail.com>
2016-11-04 10:48:38 -07:00
Joffrey F
4c3cf8e7fd
Update docs to mention new additions in Compose 1.9.0
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-11-03 15:05:24 -07:00
Gaetan de Villele
7a11f05943
fix some frontmatter keywords values
...
Signed-off-by: Gaetan de Villele <gdevillele@gmail.com>
2016-11-03 10:22:12 -07:00
Gaetan de Villele
bb4f3be02e
fix frontmatter keywords values in compose/reference/ files
...
Signed-off-by: Gaetan de Villele <gdevillele@gmail.com>
2016-11-03 10:13:21 -07:00
Adrien Duermael
8fa5f3a5de
absolute links to docs.docker.com are now relative links
...
Signed-off-by: Adrien Duermael <adrien@duermael.com>
2016-11-01 17:01:41 -07:00
Victoria Bialas
980956ef9d
incorporated misty's comments
...
Signed-off-by: Victoria Bialas <victoria.bialas@docker.com>
2016-10-31 12:43:52 -07:00
michael-wise
870abe59b4
added a filename above the custom script
...
Added a filename above the custom script to distinguish it from the wait-for-it.sh script.
2016-10-26 21:24:36 -04:00
Victoria Bialas
9c5319211d
Fixing note formatting
...
Changing note format back to the way it was to match the rest of the notes in this section.
2016-10-26 16:58:24 -07:00
Victoria Bialas
568cded2a5
finishing touches on Wordpress example in Compose docs per pr#129
...
Signed-off-by: Victoria Bialas <victoria.bialas@docker.com>
2016-10-26 13:46:53 -07:00
John Mulhausen
be3e860fa1
Merge pull request #328 from alexandair/patch-1
...
Update index.md
2016-10-25 14:25:52 -07:00
Victoria Bialas
7fd5e20337
Update ps.md
2016-10-25 11:38:33 -07:00
Victoria Bialas
e65a98ef9f
Update install.md
2016-10-25 11:24:45 -07:00
Victoria Bialas
50d7898fe4
Update gettingstarted.md
2016-10-25 11:22:30 -07:00
Victoria Bialas
100a82043a
Update gettingstarted.md
2016-10-25 11:18:39 -07:00
dave-pollock
1967bd2603
Update swarm.md
...
Scheduling filters should be configured in the environment section of compose files - NOT labels.
2016-10-25 14:57:00 +01:00
Markus Schulte
1de1d10073
At paragraph "links", fixed anchor-link to "depends-on"
2016-10-24 12:01:00 +02:00
Aleksandar Nikolić
18499881e5
Update index.md
...
Fix typo.
2016-10-23 20:12:47 +02:00
Joao Fernandes
bce5d70ce6
Updates compose install to 1.8.1
...
Signed-off-by: Joao Fernandes <joao.fernandes@docker.com>
2016-10-19 15:57:43 -07:00
DavidRabel-b1
673523ee9a
Update django.md
...
As of Django 1.10 the database backend django.db.backends.postgresql_psycopg2 is called django.db.backends.postgresql .
See https://docs.djangoproject.com/en/1.10/ref/settings/#engine
2016-10-19 17:07:49 +02:00
John Mulhausen
5d9e15dcad
Merge pull request #174 from IRus/patch-1
...
This guide used legacy backticks.
2016-10-18 16:35:17 -07:00
John Mulhausen
83ec5da00d
Merge pull request #196 from ezeeetm/patch-1
...
update 'environment' to 'labels'
2016-10-18 16:13:16 -07:00
Ivan Perez
3c41a34fd6
Typo in cd command
...
Fixes typo in command.
(If you named your directory `my_wordpress`, then you should cd into `my_wordpress`, not `my-wordpress`)
2016-10-18 20:44:36 +02:00
LRubin
3129564e3d
Merge pull request #251 from liubin/master
...
remove redundant back slash
2016-10-18 11:37:04 -07:00
Misty Stanley-Jones
01910ab6d9
Update branding for macOS
...
Apple has changed their branding guidelines from 'OS X' to 'macOS'
so we should update ours to be within trademark / branding
guidelines. See http://www.apple.com/macos/sierra/
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2016-10-18 09:21:09 -07:00
Bin Liu
c8b449e7e0
remove redundant back slash
...
I think this is a redundant back slash, should be removed.
2016-10-18 22:31:25 +08:00
ezeeetm
91b9a38864
update 'environment' to 'labels'
...
according to @aanandPrasad
constraining containers in swarm with compose is now done with 'labels' as of Swarm 0.3 and Compose 1.3
https://groups.google.com/forum/#!topic/docker-dev/Uzcies21qPo
2016-10-13 14:40:17 -07:00
nVitius
bb7661a926
Document Compose's syntax for variable defaults
...
This feature was not supported previously, but
was added in https://github.com/docker/compose/pull/3108
2016-10-12 09:50:40 -07:00
Ibragimov Ruslan
0778af3d17
This guide used legacy backticks.
...
https://github.com/koalaman/shellcheck/wiki/SC2006
https://github.com/koalaman/shellcheck/wiki/SC2046
2016-10-12 14:19:24 +03:00
BSCheshir
c98a6d8902
example pls
2016-10-08 23:35:37 +04:00
John Mulhausen
8ea375e1d7
Fix for list in compose-file, CSS fixes for blockquotes
2016-10-07 13:48:23 -07:00
BSCheshir
1b8729c5be
remove prefix space
...
strange space on ALL code block on https://docs.docker.com/compose/gettingstarted/
but github clear it on preview .md
2016-10-07 23:18:45 +04:00
sixcorners
9a2be62bf8
Update compose-file.md
...
Document that the journald logging driver allows docker-compose logs to work.
2016-10-05 11:40:42 -05:00
John Mulhausen
0133cb646d
Merge pull request #21 from pborreli/typos
...
Fixed typos
2016-09-30 11:51:42 -07:00
John Mulhausen
066b78bf86
Content rendering fixes
2016-09-30 01:51:56 -07:00
John Mulhausen
0ad083ff1f
Delete Makefile
2016-09-29 23:40:58 -07:00
John Mulhausen
d8b7717467
Delete Dockerfile
2016-09-29 23:40:48 -07:00
John Mulhausen
99bab305bd
Removing merge detritus
2016-09-29 23:38:12 -07:00
Pascal Borreli
6cd3fe8bd2
Fixed typos
2016-09-30 01:52:12 +01:00
Misty Stanley-Jones
d53c6798c9
Convert TOML to YAML, tweaks to work with Jekyll
2016-09-29 17:16:03 -07:00
Misty Stanley-Jones
9f31bb790d
Put back inadvertently deleted compose directory
2016-09-29 12:13:47 -07:00
Misty Stanley-Jones
701f170a21
Move docker-hub docs to docker-hub subdirectory
2016-09-29 10:38:52 -07:00
Misty Stanley-Jones
7629f462d5
Moved compose docs to compose subdirectory
2016-09-28 14:52:24 -07:00
Joffrey F
f3628c7a5e
Bump 1.8.0
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-07-27 11:57:23 -07:00
Aanand Prasad
e115eaf6fc
Fix error message for unrecognised TLS version
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 11:57:23 -07:00
Aanand Prasad
cefa239c2e
Bump 1.8.0-rc3
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 17:46:13 +01:00
Aanand Prasad
35ed189981
Copy experimental bundle docs into Compose docs so URL is stable
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Aanand Prasad
c392acc56b
Show a warning when engine is in swarm mode
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Ben Firshman
cd267d5121
Add user agent to API calls
...
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2016-07-27 16:27:05 +01:00
Ben Firshman
cb076a57b9
Suggest to run Docker for Mac if it isn't running
...
Instead of suggesting docker-machine.
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2016-07-27 16:27:05 +01:00
Aanand Prasad
0488dd3709
Rename --fetch-digests to --push-images and remove auto-pull
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Aanand Prasad
b72f911ccf
Fix timeout value in error message
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Aanand Prasad
f9c5816ab8
Stop checking the deprecated DOCKER_CLIENT_TIMEOUT variable
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Aanand Prasad
2ecbf25445
Fix bugs with entrypoint/command in docker-compose run
...
- When no command is passed but `--entrypoint` is, set Cmd to `[]`
- When command is a single empty string, set Cmd to `[""]`
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-27 16:27:05 +01:00
Tomas Tomecek
e1b7510e4a
service: detailed error messages for create and start
...
Fixes : #3355
Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
2016-07-27 16:27:05 +01:00
Aanand Prasad
c72c966abc
Bump 1.8.0-rc2
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-06 18:05:11 -07:00
Aanand Prasad
217f762a60
Post-merge fix - restore Environment import in main.py
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-06 16:20:18 -07:00
Joffrey F
70da16103a
Unset env vars behavior in 'run' mirroring engine
...
Unset env vars passed to `run` via command line options take the
value of the system's var with the same name.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-07-06 16:20:17 -07:00
Aanand Prasad
72849d99c0
Update bundle extension
...
It's now .dab, for Distributed Application Bundle
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-06 16:20:17 -07:00
Daniel Nephin
a7fc3e2220
Add an acceptance test for bundle.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-07-06 16:20:16 -07:00
Daniel Nephin
db02c9f537
Add some unit tests for new bundle and push commands.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-07-06 16:20:16 -07:00
Aanand Prasad
33cc601176
Warn on missing digests, don't push/pull by default
...
Add a --fetch-digests flag to automatically push/pull
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-07-06 16:20:16 -07:00
Joffrey F
9bf6bc6dbd
Bump 1.8.0-rc1
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-06-14 12:35:46 -07:00
Joffrey F
0fe82614a6
Merge pull request #3595 from dnephin/add-push-and-bundle
...
Add docker-compose push and docker-compose bundle
2016-06-14 10:57:32 -07:00
Aanand Prasad
8f8c17bf66
Merge pull request #3549 from shin-/KalleDK-master
...
Add support for COMPOSE_TLS_VERSION config option
2016-06-14 10:57:12 -07:00
Daniel Nephin
9b7bd69cfc
Support entrypoint, labels, and user in the bundle.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-06-14 13:00:12 -04:00
Aanand Prasad
1ea9dda1d3
Implement 'docker-compose push' and 'docker-compose bundle'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-06-14 12:06:14 -04:00
Aanand Prasad
21f20cbc9b
Merge pull request #3449 from Andrey9kin/ready/3281
...
Fix #3281 : Unexpected result when using build args with default values
2016-06-14 08:05:07 -07:00
Aanand Prasad
2123906586
Merge pull request #3577 from sanmai-NL/3576-byte_str_fix
...
Fix byte/str typing error
2016-06-14 01:58:27 +01:00
Joffrey F
60f7e021ad
Fix split_path_mapping behavior when mounting "/"
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-06-13 15:32:10 -07:00
Sander Maijers
61324ef308
Fix byte/str typing error
...
Signed-off-by: Sander Maijers <S.N.Maijers@gmail.com>
2016-06-10 16:30:46 +02:00
Aanand Prasad
e502417df2
Merge pull request #3475 from shin-/3429-networks-config-serialize
...
Output valid config in config command
2016-06-07 18:01:39 +02:00
Joffrey F
ea640f3821
Remove external_name from serialized config output
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-06-03 12:10:09 -07:00
Joffrey F
e7a8b2fed5
Update TLS version configuration code. Tests.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-06-03 11:45:22 -07:00
Andrey Devyatkin
a67ba5536d
Fix #3281 : Unexpected result when using build args with default values
...
Fix the issue when build arg is set to None instead of empty string. Usecase:
cat docker-compose.yml
.... args:
- http_proxy
- https_proxy
- no_proxy
If http_proxy, https_proxy, no_proxy environment variables are not defined then http_proxy,
https_proxy, no_proxy build args will be set to string None which breaks all downloads
With this change undefined build args will be set to empty string instead of string None
Signed-off-by: Andrey Devyatkin <andrey.a.devyatkin@gmail.com>
2016-05-28 11:39:41 +02:00
Andrey Devyatkin
c148849f0e
Fix #3281 : Unexpected result when using build args with default values
...
Fix the issue when build arg is set to None instead of empty string. Usecase:
cat docker-compose.yml
.... args:
- http_proxy
- https_proxy
- no_proxy
If http_proxy, https_proxy, no_proxy environment variables are not defined then http_proxy,
https_proxy, no_proxy build args will be set to string None which breaks all downloads
With this change undefined build args will be set to empty string instead of string None
Signed-off-by: Andrey Devyatkin <andrey.a.devyatkin@gmail.com>
2016-05-27 20:16:52 +02:00
Andrey Devyatkin
e3e8a619cc
Fix #3281 : Unexpected result when using build args with default values
...
Fix the issue when build arg is set to None instead of empty string.
Usecase:
cat docker-compose.yml
....
args:
- http_proxy
- https_proxy
- no_proxy
If http_proxy, https_proxy, no_proxy environment variables are not defined
then http_proxy, https_proxy, no_proxy build args will be set to string None which breaks all downloads
With this change build args will not passed to docker engine if they are equal to string None
Signed-off-by: Andrey Devyatkin <andrey.a.devyatkin@gmail.com>
2016-05-27 07:48:13 +02:00
Joffrey F
c4229b469a
Improve merging for several service config attributes
...
All uniqueItems lists in the config now receive the same treatment removing
duplicates.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-20 15:29:04 -07:00
Joffrey F
842e372258
Eliminate duplicates when merging port mappings from config files
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-20 15:28:35 -07:00
Aanand Prasad
7763122ecb
Merge pull request #3459 from shin-/2487-split-volume-path
...
Always use the Windows version of splitdrive when parsing volume mappings
2016-05-20 11:42:43 +01:00
Joffrey F
9a39208741
Merge pull request #3482 from aanand/fix-prompt-buffering
...
Fix bug where confirmation prompt doesn't show due to line buffering
2016-05-19 08:52:34 -07:00
Aanand Prasad
0c8aeb9e05
Fix bug where confirmation prompt doesn't show due to line buffering
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-05-19 15:44:17 +01:00
Joffrey F
db0a6cf2bb
Always use the Windows version of splitdrive when parsing volume mappings
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-17 16:33:59 -07:00
Joffrey F
844b7d463f
Update rm command to always remove one-off containers.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-16 14:59:33 -07:00
Joffrey F
e5645595e3
Fail gracefully when -d is not provided for exec command on Win32
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-12 14:00:54 -07:00
Aanand Prasad
72f6a5c8d3
Merge pull request #3433 from anton44eg/issue_3432
...
add msg attribute to ProjectError class
2016-05-12 16:55:11 +01:00
Joffrey F
dc88e54010
Merge pull request #3399 from yorkedork/fix/env-file-validation
...
Adds additional validation to 'env_vars_from_file'.
2016-05-12 08:53:25 -07:00
Anton Simernia
4b01f6dcd6
add msg attribute to ProjectError class
...
Signed-off-by: Anton Simernia <anton.simernya@gmail.com>
2016-05-09 18:26:20 +07:00
Joffrey F
310b3d9441
Properly handle APIError failures in Project.up
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-05-02 13:42:05 -07:00
Thom Linton
28fb91b344
Adds additional validation to 'env_vars_from_file'.
...
The 'env_file' directive and feature precludes the use of the name
'.env' in the path shared with 'docker-config.yml', regardless of
whether or not it is enabled.
This change adds an additional validation to allow the use of this
path provided it is not a file.
Signed-off-by: Thom Linton <thom.linton@gmail.com>
2016-04-29 17:53:31 -07:00
Joffrey F
fe17e0f948
Skip event objects that don't contain a status field
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-04-29 16:39:42 -07:00
Joffrey F
bd7ec24e25
Merge pull request #3384 from shin-/3264-shorthand-host-support
...
Support combination of shorthand flag and equal sign for host option
2016-04-29 16:39:16 -07:00
Joffrey F
8cc7d68a00
Merge pull request #3390 from aronahl/master
...
Add missing log event filter when using docker-compose logs.
2016-04-28 12:53:04 -07:00
Joffrey F
0b24883cef
Support combination of shorthand flag and equal sign for host option
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-04-28 12:52:00 -07:00
Aaron Nall
2efcec776c
Add missing log event filter when using docker-compose logs.
...
Signed-off-by: Aaron Nall <aronahl@hotmail.com>
2016-04-28 15:14:44 +00:00
Daniel Nephin
61794ba97c
Merge pull request #3377 from shin-/3372-windowserror
...
Define WindowsError on non-win32 platforms
2016-04-28 10:33:18 -04:00
Joffrey F
d3e645488a
Define WindowsError on non-win32 platforms
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-04-26 11:40:31 -07:00
Aanand Prasad
756ef14edc
Fix format of 'restart' option in 'config' output
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-26 19:21:03 +01:00
Aanand Prasad
6064d200f9
Fix output of 'config' for v1 files
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-26 19:21:03 +01:00
Ben Firshman
b67f110620
Explain the explanation about file versions
...
This explanation looked like it was part of the error. Added an
extra new line and a bit of copy to explain the explanation.
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2016-04-20 16:40:16 -07:00
Ben Firshman
27628f8655
Make validation error less robotic
...
"ERROR: Validation failed in file './docker-compose.yml', reason(s):"
is now:
"ERROR: The Compose file './docker-compose.yml' is invalid because:"
Signed-off-by: Ben Firshman <ben@firshman.co.uk>
2016-04-20 16:38:09 -07:00
Aanand Prasad
cafe1315b2
Merge pull request #3334 from werehuman/fix-config-hash-change
...
Fix #3248 : Accidental config_hash change
2016-04-19 12:42:19 +01:00
Aanand Prasad
984f839d33
Merge pull request #3263 from twitherspoon/3191_2_help_cli_feature
...
Added code to support no argument help command
2016-04-19 12:14:24 +01:00
Aanand Prasad
d21e1c5a30
Merge pull request #3335 from johnharris85/master
...
Fix CLI docstring to reflect Docopt behaviour.
2016-04-19 12:13:20 +01:00
Aanand Prasad
52fa010ac7
Merge pull request #3337 from dnephin/check_for_short_id_alias
...
Check for short id alias, and don't disconnect if it already exists
2016-04-19 12:12:43 +01:00
johnharris85
6d2805917c
Account for aliased links
...
Fix failing tests
Signed-off-by: John Harris <john@johnharris.io>
2016-04-17 15:25:06 -04:00
johnharris85
68272b0216
Config now catches undefined service links
...
Fixes issue #2922
Signed-off-by: John Harris <john@johnharris.io>
2016-04-17 14:00:07 -04:00
Daniel Nephin
56c6e29819
Unit test for skipping network disconnect.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-15 16:28:59 -04:00
Vladimir Lagunov
4702703615
Fix #3248 : Accidental config_hash change
...
Signed-off-by: Vladimir Lagunov <lagunov.vladimir@gmail.com>
2016-04-15 15:34:30 +03:00
johnharris85
ad306f0479
Fix CLI docstring to reflect Docopt behaviour.
...
Signed-off-by: John Harris <john@johnharris.io>
2016-04-15 13:30:13 +01:00
Daniel Nephin
e1356e1f6f
Set networking_config when creating a container.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-14 18:09:06 -04:00
Daniel Nephin
abb5ae7fe4
Only disconnect if we don't already have the short id alias.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-14 16:05:14 -04:00
Aanand Prasad
e2cb7b0237
Merge pull request #3299 from dannyprout/2096-only-show-port-clash-warning-when-starting-multiple-containers
...
Only show port clash warning if multiple containers are about to be started
2016-04-14 10:40:02 +01:00
Daniel Nephin
50287722f2
Update release notes and set version to 1.8.0dev
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-13 13:27:18 -04:00
Danyal Prout
339ebc0483
Fixes #2096 : Only show multiple port clash warning if multiple containers
...
are about to be started.
Signed-off-by: Danyal Prout <me@dany.al>
2016-04-12 20:58:21 +01:00
Aanand Prasad
3d3f331404
Merge pull request #3303 from aanand/clarify-rm-and-down
...
Clarify behaviour of rm and down
2016-04-12 11:31:22 +01:00
Aanand Prasad
7cfb5e7bc9
Fix race condition
...
If processing of all objects finishes before the queue is drained,
parallel_execute_iter() returns prematurely.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-11 17:05:52 +01:00
Aanand Prasad
3722bb38c6
Clarify behaviour of rm and down
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-11 16:31:27 +01:00
Aanand Prasad
15c5bc2e6c
Rename a couple of functions in parallel.py
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-11 13:05:30 +01:00
Aanand Prasad
0671b8b8c3
Document parallel helper functions
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-11 12:51:27 +01:00
Aanand Prasad
0e3db185cf
Small refactor to feed_queue()
...
Put the event tuple into the results queue rather than yielding it from
the function.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-11 12:37:00 +01:00
Daniel Nephin
83df95d511
Remove extra ensure_image_exists() which causes duplicate builds.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-08 15:21:12 -04:00
Aanand Prasad
be27e266da
Reduce queue timeout
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 19:07:40 +01:00
Aanand Prasad
5450a67c2d
Hold state in an object
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 19:06:07 +01:00
Aanand Prasad
54b6fc4219
Refactor so there's only one queue
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 18:54:02 +01:00
Aanand Prasad
af9526fb82
Move queue logic out of parallel_execute()
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 18:30:28 +01:00
Aanand Prasad
141b96bb31
Abort operations if their dependencies fail
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 17:51:09 +01:00
Aanand Prasad
bcdf541c8c
Refactor setup_queue()
...
- Stop sharing set objects across threads
- Use a second queue to signal when producer threads are done
- Use a single consumer thread to check dependencies and kick off new
producers
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-04-08 16:24:29 +01:00
twitherspoon
9f47e43b5c
Merge branch 'master' into 3191_2_help_cli_feature
2016-04-07 12:43:34 -04:00
Daniel Nephin
b33d7b3dd8
Prevent unnecessary inspection of containers when created from an inspect.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-04-06 11:14:42 -04:00
Tony Witherspoon
129fb5b356
Added code to output the top level command options if docker-compose help with no command options provided
...
Signed-off-by: Tony Witherspoon <tony.witherspoon@gmail.com>
2016-04-04 13:15:28 -04:00
Joffrey F
78a8be07ad
Re-enabling assert_hostname when instantiating docker_client from the
...
environment.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-30 11:11:19 -07:00
Joffrey F
71c86acaa4
Update docker-py version to include match_hostname fix
...
Removed unnecessary assert_hostname computation in tls_config_from_options
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-29 18:01:27 -07:00
Joffrey F
7116aefe43
Fix assert_hostname logic in tls_config_from_options
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-28 17:39:20 -07:00
Joffrey F
12ad3ff301
Injecting os.environ in Environment instance happens outside of init method
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:28 -07:00
Joffrey F
1506f997de
Better windows support for Environment class
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:28 -07:00
Joffrey F
b99037b4a6
Add support for DOCKER_* variables in .env file
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:28 -07:00
Joffrey F
c7afe16419
Account for case-insensitive env on windows platform
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
36f1b4589c
Limit occurrences of creating an environment object.
...
.env file is always read from the project_dir
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
0ff53d9668
Less verbose environment invocation
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
f48da96e8b
Test get_project_name from env file
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
1801f83bb8
Environment class cleanup
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
b9ca5188a2
Remove Environment singleton, instead carry instance during config processing
...
Project name and compose file detection also updated
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Joffrey F
c69d8a3bd2
Implement environment singleton to be accessed throughout the code
...
Load and parse environment file from working dir
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-24 10:57:01 -07:00
Aanand Prasad
c3eca82749
Merge pull request #3128 from dnephin/add_network_settings_to_config_hash
...
Include network settings as part of the service config hash.
2016-03-23 17:01:32 +00:00
Joffrey F
2cc87555cb
tls_config_from_options unit tests
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-22 11:57:45 -07:00
Joffrey F
442dff72b4
Improve assert_hostname setting in tls_config_from_options
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-22 11:47:53 -07:00
Joffrey F
26f3861791
Specifying --tls no longer overrides all other TLS options
...
Add an option to skip hostname verification
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-22 11:47:53 -07:00
Joffrey F
7166408d2a
Fixed typos + simplified TLSConfig creation process.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-22 11:47:53 -07:00
Joffrey F
1ac33ea7e5
Add support for TLS config command-line options
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-22 11:47:53 -07:00
Aanand Prasad
4f5123bda9
Merge pull request #3168 from dnephin/fix_tty_timeout
...
Handle all timeout errors consistently
2016-03-22 10:14:52 +00:00
Aanand Prasad
aaa7b09369
Merge pull request #3181 from dnephin/fix_partial_change_test_failure
...
Fix flaky partial_change state test
2016-03-22 10:14:28 +00:00
Aanand Prasad
a20b84e6d2
Merge pull request #3178 from aanand/2774-off-one-offs
...
Remove one-off containers in `rm` and `down`
2016-03-22 10:12:21 +00:00
Daniel Nephin
5c968f9e15
Fix flaky partial_change state test.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-21 19:07:50 -04:00
Daniel Nephin
be1476f24b
Only allow tmpfs on v2.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-21 14:41:28 -04:00
Aanand Prasad
2bf5e46857
Stop and remove still-running one-off containers in 'down'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-21 18:08:07 +00:00
Aanand Prasad
a2317dfac2
Remove one-off containers in 'docker-compose down'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-21 16:15:49 +00:00
Aanand Prasad
81f6d86ad9
Warn when --all is not passed to rm
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-21 15:14:31 +00:00
Aanand Prasad
1bc9469674
Don't allow boolean values for one_off in Project methods
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-21 14:42:57 +00:00
Joffrey F
5826a2147b
Use enum to represent 3 possible states of the one_off filter
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-21 12:12:52 +00:00
Joffrey F
187ea4cd81
Add --all option to rm command - remove one-off containers
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-21 12:12:52 +00:00
Kalle Møller
7fc40dd7cc
Adding ssl_version to docker_clients kwargs
...
Select tls version based of COMPOSE_TLS_VERSION
Changed from SSL to TLS
Also did docs - missing default value
Using getattr and raises AttributeError in case of unsupported version
Signed-off-by: Kalle Møller <github.com@k-moeller.dk>
2016-03-19 01:15:03 +01:00
Daniel Nephin
089ec66522
Include network settings as part of the service config hash.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-18 18:20:03 -04:00
Philip Walls
85c7d3e5ce
Add support for docker run --tmpfs flag.
...
Signed-off-by: Philip Walls <pawalls@rabidgeek.com>
2016-03-18 18:19:48 -04:00
Daniel Nephin
f1dce50b3d
Handle all timeout errors consistently.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-18 18:19:35 -04:00
Aanand Prasad
72ed4d3f97
Merge pull request #3152 from aanand/update-mac-install-url
...
Update Mac Engine install URL in error message
2016-03-17 17:56:34 +00:00
Thomas Grainger
20bf05a6e3
Fix TypeError in Exception handling
...
Traceback (most recent call last):
File "/tmp/tmp.02tgGaAGtW/docker-compose/bin/docker-compose", line 11, in <module>
sys.exit(main())
File "/tmp/tmp.02tgGaAGtW/docker-compose/lib/python3.4/site-packages/compose/cli/main.py", line 68, in main
log_api_error(e)
File "/tmp/tmp.02tgGaAGtW/docker-compose/lib/python3.4/site-packages/compose/cli/main.py", line 89, in log_api_error
if 'client is newer than server' in e.explanation:
TypeError: 'str' does not support the buffer interface
Signed-off-by: Thomas Grainger <tagrain@gmail.com>
2016-03-17 15:13:01 +00:00
Aanand Prasad
92d69b0cb6
Update Mac Engine install URL in error message
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-17 09:56:44 +00:00
Aanand Prasad
371ea479f5
Merge pull request #3075 from dnephin/reactive_logs
...
Display logs for new containers started after the command is run
2016-03-16 21:03:25 +00:00
Aanand Prasad
abddabfb0a
Merge pull request #3135 from dnephin/fix_down_idempotency
...
Make down idempotent, continue to remove resources if one is missing
2016-03-16 20:26:18 +00:00
Joffrey F
dd40331b44
Merge pull request #3102 from shin-/1477-a-modest-proposal
...
Add flag to up/down to remove orphaned containers
2016-03-16 10:58:15 -07:00
Joffrey F
20c29f7e47
Add flag to up/down to remove orphaned containers
...
Add --remove-orphans to CLI reference docs
Add --remove-orphans to bash completion file
Test orphan warning and remove_orphan option in up
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-15 16:11:49 -07:00
Daniel Nephin
52b791a264
Split off build_container_options() to reduce the complexity of run
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 15:29:24 -04:00
Simon van der Veldt
658803edf8
Add -w or --workdir to compose run to override workdir from commandline
...
Signed-off-by: Simon van der Veldt <simon.vanderveldt@gmail.com>
2016-03-15 15:28:32 -04:00
Daniel Nephin
bf96edfe11
Reduce the args of some functions by including presenters as part of the thread_args.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 15:15:00 -04:00
Daniel Nephin
e5529a89e1
Make down idempotent, continue to remove resources if one is missing.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:26:29 -04:00
Daniel Nephin
e8a93821d4
Fix race condition where a container stopping and starting again would cause logs to miss logs.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:11 -04:00
Daniel Nephin
3f7e5bf768
Filter logs by service names.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:10 -04:00
Daniel Nephin
48ed68eeaa
Fix geneartors for python3.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:10 -04:00
Daniel Nephin
4cad2a0c5f
Handle events for removed containers.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:10 -04:00
Daniel Nephin
44c1747127
Add tests for reactive log printing.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:10 -04:00
Daniel Nephin
65797558f8
Refactor log printing to support containers that are started later.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-15 13:17:10 -04:00
Ilya Skriblovsky
34de1f0a4c
Removed unused parallel.parallel_stop
...
Signed-off-by: Ilya Skriblovsky <IlyaSkriblovsky@gmail.com>
2016-03-14 22:56:58 +03:00
Ilya Skriblovsky
f933381a12
Dependency-ordered start/stop/up
...
Signed-off-by: Ilya Skriblovsky <IlyaSkriblovsky@gmail.com>
2016-03-14 22:55:42 +03:00
Aanand Prasad
e5cd869c61
Merge pull request #3095 from dnephin/refactor_command_dispatch
...
Refactor command dispatch and fix api version mismatch error
2016-03-14 16:18:29 +00:00
Matt Daue
ee136446a2
Fix #2804 : Add ipv4 and ipv6 static addressing
...
- Added ipv4_network and ipv6_network to the networks section in the
service section for each configured network
- Added feature documentation
- Added unit tests
Signed-off-by: Matt Daue <mattdaue@gmail.com>
2016-03-09 18:37:52 -05:00
Joffrey F
7033042656
Merge pull request #3039 from dbonev/3020-build-arguments-object-syntax
...
Allowing null for build args
2016-03-09 10:55:05 -08:00
Daniel Nephin
0a091055d2
Improve handling of connection errors and error messages.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-08 15:39:11 -05:00
Daniel Nephin
9f9dcc098a
Make TopLevelCommand use the project field.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-08 14:36:53 -05:00
Daniel Nephin
53bea8a720
Refactor command dispatch to improve unit testing and support better error messages.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-08 14:23:27 -05:00
Joffrey F
d2b065e615
Don't raise ConfigurationError for volume driver mismatch
...
when driver is unspecified
Add testcase
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-07 18:07:41 -08:00
Joffrey F
698998c410
Don't call create on existing volumes
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-03-07 18:00:27 -08:00
Dimitar Bonev
81b7fba33e
Allowing null for build args
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-03-05 15:57:06 +02:00
Aanand Prasad
9e242cdc75
Merge pull request #3032 from dnephin/multiple_files_from_env_var
...
Support multiple files in COMPOSE_FILE env var
2016-03-03 17:23:22 +00:00
Aanand Prasad
4ae71f41dd
Merge pull request #2832 from aanand/refactor-cli-unit-tests
...
Refactor CLI initialization and unit tests
2016-03-02 16:10:44 -08:00
Daniel Nephin
53a3d14046
Support multiple files in COMPOSE_FILE env var.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-02 18:47:58 -05:00
Aanand Prasad
575b48749d
Remove unused global_options arg from dispatch()
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-03-02 15:09:48 -08:00
Aanand Prasad
f75408923e
Merge pull request #3053 from dnephin/handle_booleans_in_mappings
...
Don't allow booleans for mapping types
2016-03-02 15:04:20 -08:00
Aanand Prasad
3f98c0716e
Merge pull request #3052 from dnephin/merge_v1_logging
...
Fix merging of logging options in v1 config
2016-03-02 15:03:36 -08:00
Daniel Nephin
e1b87d7be0
Update reference docs for the new flag.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-02 15:32:51 -05:00
Daniel Nephin
b7fb3a6d9b
Add --build flag for up and create
...
Also adds a warning when up builds an image without the --build flag
so that users know it wont happen on the next up.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-02 15:32:51 -05:00
Aanand Prasad
0b3561a7d5
Merge pull request #2720 from seguins/2227-improvements-logs
...
Add flags on logs
2016-03-01 17:41:31 -08:00
Daniel Nephin
ed4473c849
Fix signal handling with pyinstaller.
...
Raise a ShutdownException instead of a KeyboardInterupt when a thread.error
is caught. This thread.error is only raised when run from a pyinstaller
binary (for reasons unknown).
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-01 16:39:43 -05:00
Stéphane Seguin
038da4eea3
Logs args of LogPrinter as a dictionary
...
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2016-03-01 20:24:15 +01:00
Stéphane Seguin
9b36dc5c54
Add --tail flag as option on logs.
...
Closes #265
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2016-03-01 20:23:46 +01:00
Stéphane Seguin
d9b4286f91
Add -t, --timestamps flag as option on logs.
...
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2016-03-01 20:23:46 +01:00
Stéphane Seguin
82632098a3
Add -f, --follow flag as option on logs.
...
Closes #2187
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2016-03-01 20:23:43 +01:00
Daniel Nephin
18510b4024
Don't allow booleans for mapping types.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-01 11:57:35 -05:00
Daniel Nephin
b726f508a6
Fix merging of logging options in v1 config.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-03-01 11:43:26 -05:00
Aanand Prasad
210856179d
Merge pull request #3036 from JesusTinoco/master
...
Display in the log output the name of those containers created using …
2016-02-29 15:17:14 -08:00
Jesus
6bfb23baaa
Display containers name when scale a container
...
Display in the log output the name of those containers created using the scale command and
change the test_scale_with_api_error test to support the containers name when scale
Signed-off-by: Jesus Rodriguez Tinoco <jesus.rodriguez.tinoco@gmail.com>
2016-02-29 20:19:03 +01:00
Tomas Tomecek
d28c5dda92
implement exec
...
Resolves #593
Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
2016-02-29 10:50:09 +01:00
Aanand Prasad
adb8de367e
Merge pull request #2388 from dnephin/fix_long_lines
...
Wrap long lines
2016-02-25 16:52:33 -08:00
Aanand Prasad
42f4d814d7
Merge pull request #2880 from dnephin/merge_jsonschemas
...
Merge jsonschemas to a single schema file per version
2016-02-25 16:51:56 -08:00
Daniel Nephin
dc3a5ce624
Refactor config validation to support constraints in the same jsonschema
...
Reworked the two schema validation functions to read from the same schema but
use different parts of it. Error handling is now split as well by the
schema that is being used to validate.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 16:20:17 -08:00
Daniel Nephin
43ecf8793a
Address old TODO, and small refactor of container name logic in service.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 16:19:38 -08:00
Daniel Nephin
cdda616d6b
Reduce complexity of sort_service_dicts.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 16:19:38 -08:00
Daniel Nephin
84a1822e40
Reduce complexity of _get_container_create_options
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 16:19:38 -08:00
Daniel Nephin
be554c3a74
Merge v1 config jsonschemas into a single file.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 15:59:10 -08:00
Daniel Nephin
adb64ef8d5
Merge v2 config jsonschemas into a single file.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-24 15:59:10 -08:00
Daniel Nephin
d451578152
Make environment variables without a value the same as docker-cli.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-23 11:14:59 -08:00
Daniel Nephin
4b04280db8
Revert "Change special case from '_', None to ()"
...
This reverts commit 677c50650c
.
Revert "Modify service_test.py::ServiceTest::test_resolve_env to reflect new behavior"
This reverts commit 0019037712
.
Revert "Mangle the tests. They pass for better or worse!"
This reverts commit 7ab9509ce6
.
Revert "If an env var is passthrough but not defined on the host don't set it."
This reverts commit 6540efb3d3
.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-23 11:13:57 -08:00
Daniel Nephin
1d67e6f0f0
Merge pull request #2995 from dnephin/fix_warning_about_bools
...
Fix warning about boolean values
2016-02-23 11:11:54 -08:00
Daniel Nephin
ba799d2e86
Merge pull request #2996 from dnephin/fix_abort_on_container_exit
...
Fix abort on container exit
2016-02-23 10:52:12 -08:00
Daniel Nephin
15b2094bad
Stop other containers if the flag is set.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-22 16:48:46 -08:00
Richard Bann
bf2bf21720
Add failing test for --abort-on-container-exit
...
Handle --abort-on-container-exit. Fixes #2940
Signed-off-by: Richard Bann <richardbann@gmail.com>
2016-02-22 16:39:40 -08:00
Daniel Nephin
0a06d827fa
Fix warning about boolean values.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-22 14:56:01 -08:00
Daniel Nephin
d5514965d5
Merge pull request #2975 from dnephin/fix_crash_on_none_in_config
...
Fix validation message when there are multiple nested oneOf validations.
2016-02-19 15:53:26 -05:00
Daniel Nephin
02535f0cf1
Fix validation message when there are multiple ested oneOf validations.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-19 14:22:55 -05:00
Daniel Nephin
0d218c34c7
Make config validation error messages more consistent.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-19 13:12:57 -05:00
Daniel Nephin
4b2a666231
Validate that each section of the config is a mapping before running interpolation.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-19 12:38:52 -05:00
Joffrey F
0cb8ba3775
Use modern set notation in _get_aliases
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:28:12 -08:00
Joffrey F
7152f7ea76
Handle mismatched network formats in config files
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:24:41 -08:00
Joffrey F
825a0941f0
Network aliases are now part of the network dictionary
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:23:47 -08:00
Joffrey F
41e399be98
Fix network list serialization in py3
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:23:47 -08:00
Joffrey F
633e349ab9
Test network_aliases feature
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:23:46 -08:00
Joffrey F
2b5d3f51cb
Allow user to specify custom network aliases
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 15:23:46 -08:00
Joffrey F
d3a95c2892
Merge pull request #2938 from shin-/2927-buildargs-types
...
Constraint build argument types. Numbers are cast into strings.
2016-02-18 15:07:09 -08:00
Joffrey F
93a02e497d
Apply driver_opts processing to network configs
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-18 10:53:40 -08:00
Daniel Nephin
4f7530c480
Only set a container affinity if there are volumes to copy over.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-17 22:35:14 -05:00
Joffrey F
1952b52392
Constraint build argument types. Numbers are cast into strings
...
Numerical driver_opts are also valid and typecast into strings.
Additional config tests.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-17 11:53:29 -08:00
Daniel Nephin
4a09da43ea
Fix copying of volumes by using the name of the volume instead of the host path.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-17 13:34:14 -05:00
Daniel Nephin
74dc1b1411
Merge pull request #2893 from shin-/2833-run-dependencies
...
Bring up all dependencies when running a single service.
2016-02-12 16:33:01 -05:00
Joffrey F
a8fda480e3
driver_opts can only be of type string
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-12 10:51:11 -08:00
Joffrey F
367fabdbfa
Bring up all dependencies when running a single service.
...
Added test for running a depends_on service
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-12 09:46:10 -08:00
Joffrey F
e1d67ad68a
Merge pull request #2882 from shin-/2715-old-server-error
...
Detailed error message when daemon version is too old.
2016-02-11 16:03:20 -08:00
Daniel Nephin
b6812b8600
Merge pull request #2877 from dnephin/fix_merging_build
...
Fix build section without context
2016-02-11 18:53:23 -05:00
Joffrey F
79f993f52c
Detailed error message when daemon version is too old.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-11 15:20:32 -08:00
Joffrey F
e225f12551
Add logging when initializing a volume.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-02-11 11:40:22 -08:00
Daniel Nephin
532dffd688
Fix build section without context.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-11 14:12:02 -05:00
Aanand Prasad
23ab2c7e44
Merge pull request #2878 from dnephin/merge_build_args
...
Merge build.args when merging services
2016-02-11 17:41:41 +00:00
Spencer Rinehart
ab40d389d0
Fix sorting of DOCKER_START_KEYS.
...
Make sure it's sorted!
Signed-off-by: Spencer Rinehart <anubis@overthemonkey.com>
2016-02-10 15:25:18 -06:00
Spencer Rinehart
5e6dc3521c
Add support for shm_size. Fixes #2823 .
...
shm_size controls the size of /dev/shm in the container and requires
Docker 1.10 or newer (API version 1.22). This requires docker-py 1.8.0
(docker/docker-py#923 ).
Similar to fields like `mem_limit`, `shm_size` may be specified as
either an integer or a string (e.g., `64M`).
Updating docker-py to the master branch in order to get the unreleased
dependency on `shm_size` there in place.
Signed-off-by: Spencer Rinehart <anubis@overthemonkey.com>
2016-02-10 15:25:18 -06:00
Daniel Nephin
37564a73c3
Merge build.args when merging services.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-10 13:54:40 -05:00
Aanand Prasad
7b5bad6050
Merge pull request #2851 from cr7pt0gr4ph7/2839-fix-networks-merging
...
Fix merge behavior for 'networks' and 'network_mode'.
2016-02-10 17:51:01 +00:00
Daniel Nephin
6f06b3bd30
Merge pull request #2853 from dnephin/fix_short_id_alias
...
Use 12 characters for the short id
2016-02-09 14:56:24 -05:00
Joffrey F
fdf4a2e89e
Merge pull request #2734 from jrabbit/empty-env-var-2359
...
Empty env var #2359
2016-02-08 11:17:54 -08:00
Daniel Nephin
421981e7d2
Use 12 characters for the short id to match docker and fix backwards compatibility.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-08 12:18:48 -05:00
Lukas Waslowski
5bd88f634f
Handle the 'network_mode' key when merging multiple compose files.
...
Fixes docker/compose#2840 .
Signed-off-by: Lukas Waslowski <cr7pt0gr4ph7@gmail.com>
2016-02-08 15:33:26 +01:00
Lukas Waslowski
5a3a10d43b
Correctly merge the 'services/<service>/networks' key in the case of multiple compose files.
...
Fixes docker/compose#2839 .
Signed-off-by: Lukas Waslowski <cr7pt0gr4ph7@gmail.com>
2016-02-08 15:17:21 +01:00
jrabbit
677c50650c
Change special case from '_', None to ()
...
Signed-off-by: jrabbit <jackjrabbit@gmail.com>
2016-02-06 02:54:06 -05:00
Daniel Nephin
57fc85b457
Wrap long lines and restrict lines to 105 characters.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-04 19:05:39 -05:00
Aanand Prasad
869e815213
Bump 1.7.0dev
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-04 23:46:41 +00:00
Aanand Prasad
be236d8801
Update docker-py and dockerpty
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-04 19:16:01 +00:00
Daniel Nephin
80d02e84e2
Merge pull request #2808 from aanand/connect-before-start
...
Connect container to networks before starting it
2016-02-03 23:49:56 -05:00
Daniel Nephin
89c5b800e6
Merge pull request #2782 from dbonev/2772-compose-project-name-empty
...
Falling back to default project name on empty COMPOSE_PROJECT_NAME
2016-02-02 20:37:38 -05:00
Aanand Prasad
2651c00f0c
Connect container to networks before starting it
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 19:31:49 +00:00
Daniel Nephin
4c4e94bc19
Merge pull request #2785 from dnephin/depends_on_with_extends
...
Fix list options when used with extends and multiple files
2016-02-02 13:36:46 -05:00
Daniel Nephin
3d3388d59b
Extract volume init and removal from project.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:53:04 -05:00
Daniel Nephin
e551988616
Include networks in the config_hash.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:52:03 -05:00
Daniel Nephin
0810eeba10
Don't initialize networks that aren't used by any services.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:52:03 -05:00
Daniel Nephin
8e838968fe
Refactor project network initlization.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:51:31 -05:00
Daniel Nephin
e32863f89e
Make links unique-by-alias when merging
...
Factor out MergeDict from merge_service_dicts to reduce complexity below limit.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:48:47 -05:00
Daniel Nephin
bf6a5d3e49
Fix merging of lists with multiple files.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-02-02 10:48:18 -05:00
Ryan Taylor Long
c70c72f49a
Add depends_on to ALLOWED_KEYS
...
This ensures and already existing `depends_on` is not deleted when the service on which it is defined also employs `extends`.
Signed-off-by: Ryan Taylor Long <ryan@rtlong.com>
2016-02-02 10:48:18 -05:00
Aanand Prasad
1152c5b25b
Tweak and test warning shown when version is a dict
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 13:58:34 +00:00
Aanand Prasad
ef8db3650a
Improve error messages for invalid versions
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 13:58:34 +00:00
Aanand Prasad
aeef61fcd8
Make 'version' a string
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 13:58:34 +00:00
Aanand Prasad
a8de582425
Remove redundant check - self.config should never be None
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 13:47:44 +00:00
Aanand Prasad
4ac004059a
Normalise/fix config field designators in validation messages
...
- Instead of "Service 'web' configuration key 'image'", just say
"web.image"
- Fix the "Service 'services'" bug in the v2 file format
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-02-02 13:47:43 +00:00
Dimitar Bonev
34ccb90d7e
Falling back to default project name when COMPOSE_PROJECT_NAME is set to empty
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-01-30 10:14:45 +02:00
Daniel Nephin
b4868d0259
Fix race condition with up and setting signal handlers.
...
Also print stdout on wait_for_container().
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-29 13:04:04 -05:00
Daniel Nephin
883e45626f
Merge pull request #2706 from dnephin/dont_copy_host_volumes
...
Don't copy host volumes on recreate
2016-01-28 15:02:53 -05:00
Aanand Prasad
ca81672b82
Merge pull request #2761 from aanand/fix-bridge-plus-host
...
Remove ability to join bridge network + user-defined networks
2016-01-27 01:41:07 +00:00
Aanand Prasad
650b0cec38
Remove ability to join bridge network + user-defined networks
...
Containers connected to the bridge network can't have aliases, so it's
simpler to rule that they can *either* be connected to the bridge
network (via `network_mode: bridge`) *or* be connected to user-defined
networks (via `networks` or the default network).
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-27 00:42:09 +00:00
Aanand Prasad
0ba02b4a18
Add back external links in v2
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-26 18:48:43 +00:00
Aanand Prasad
ed1b204804
Rename 'net' to 'network mode' in various classes/methods
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-25 23:55:20 +00:00
Aanand Prasad
e566a4dc1c
Implement network_mode in v2
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-25 23:24:55 +00:00
Aanand Prasad
a267d8fe3c
Merge pull request #2728 from shin-/2709_service_volumes
...
Match named volumes in service definitions with declared volumes
2016-01-25 23:24:09 +00:00
Joffrey F
af6b18cad8
Merge pull request #2746 from aanand/alias-containers-by-short-id
...
Alias containers by short id
2016-01-25 13:55:30 -08:00
Aanand Prasad
313c584185
Alias containers by short id
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-25 16:14:21 +00:00
jrabbit
6540efb3d3
If an env var is passthrough but not defined on the host don't set it.
...
This doesn't change too much code and keeps the generators.
Signed-off-by: jrabbit <jackjrabbit@gmail.com>
2016-01-23 15:58:06 -05:00
Joffrey F
139c7f7830
Move named volumes matching to config validation phase
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-22 17:42:24 -08:00
Joffrey F
48377a354f
is_named_volume also tests for home paths ~
...
Fix bug with VolumeSpec not being updated
Fix integration test
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-22 16:05:21 -08:00
Dimitar Bonev
3a72edb906
Network fields schema validation
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-01-22 16:42:10 +02:00
Joffrey F
9e67eae311
Match named volumes in service definitions with declared volumes
...
Raise ConfigurationError for undeclared named volumes
Test new behavior
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-21 18:10:53 -08:00
Alf Lervag
6e73fb38ea
Fixes #2448
...
Signed-off-by: Alf Lervag <alf.lervag@bouvet.no>
Conflicts:
compose/cli/main.py
requirements.txt
2016-01-21 19:19:37 +00:00
Aanand Prasad
f3e55568d1
Fix interactive run with networking
...
Make sure we connect the container to all required networks *after*
starting the container and *before* hijacking the terminal.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 18:42:59 +00:00
Aanand Prasad
09dbc7b4cb
Stop connecting to all networks on container creation
...
This relies on an Engine behaviour which is a bug, not an intentional
feature - we have to connect to networks one at a time
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 18:04:50 +00:00
Aanand Prasad
a14906fd35
Fix 'run' behaviour with networks
...
- Test that one-off containers join all networks
- Don't set any aliases
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 17:28:55 +00:00
Aanand Prasad
1e51b7e88b
Merge pull request #2722 from aanand/fix-scale-race-condition
...
Fix scale race condition
2016-01-21 17:08:15 +00:00
Aanand Prasad
013c5ea3f9
Merge pull request #2713 from aanand/links-v2
...
Support links in v2 files
2016-01-21 17:08:05 +00:00
Aanand Prasad
7a4fdfd034
Merge pull request #2712 from jzvelc/fix_v2_service_extend
...
Fix `extends` when using v2 config format
2016-01-21 17:06:21 +00:00
Aanand Prasad
642e71b4c7
Stop and remove containers in parallel when scaling down
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 15:28:40 +00:00
Aanand Prasad
755c49b500
Fix scale when containers exit immediately
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 15:19:55 +00:00
Aanand Prasad
ee63075a34
Support links in v2 files
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-21 14:34:26 +00:00
Jure Žvelc
907c3ce42b
Fix for extending services written in v2 format.
...
Signed-off-by: Jure Žvelc <jzvelc@gmail.com>
2016-01-20 18:46:16 +01:00
Daniel Nephin
146587643c
Move ulimits validation to validation.py and improve the error message.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-19 15:47:57 -05:00
Daniel Nephin
0bce467782
Implement depends_on to define an order for services in the v2 format.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-19 15:41:45 -05:00
Daniel Nephin
c39489f540
Don't copy over volumes that were previously host volumes, and are now container volumes.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-19 14:41:21 -05:00
Daniel Nephin
c47aea9c12
Merge pull request #2698 from aanand/fix-name-is-reserved
...
Fix "name is reserved" with Engine 1.10 RC1
2016-01-19 10:15:06 -05:00
Aanand Prasad
2106481c23
Fix "name is reserved" with Engine 1.10 RC1
...
Ensure link aliases are unique (this deduping was previously performed
on the server).
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-19 11:27:27 +00:00
Aanand Prasad
5b2b4cbb07
Merge pull request #2692 from aanand/fix-tls-paramater-error
...
Catch TLSParameterErrors from docker-py
2016-01-19 11:25:21 +00:00
Aanand Prasad
9ccef1ea91
Catch TLSParameterErrors from docker-py
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-18 21:48:12 +00:00
Aanand Prasad
afae365050
Allow custom ipam config
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-18 18:56:18 +00:00
Aanand Prasad
e7673bf920
Allow overriding of config for the default network
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-18 16:17:39 +00:00
Aanand Prasad
53d56ea245
Quote network names in error messages
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-18 16:15:52 +00:00
Daniel Nephin
cce3b29688
Merge pull request #2665 from dnephin/check_extends_use_same_version
...
Validate that an extended config file has the same version as the base
2016-01-15 18:07:56 -05:00
Daniel Nephin
dc1104649f
Validate that an extended config file has the same version as the base.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 22:28:20 -05:00
Aanand Prasad
cba75627e1
Fix error when joining host/bridge network
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-15 02:46:24 +00:00
Aanand Prasad
abd031cb3d
Containers join each network aliased to their service's name
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-15 02:08:20 +00:00
Daniel Nephin
2a2eb81215
Merge pull request #2662 from dnephin/fix_config_printing_unicode
...
Fix config printing unicode objects
2016-01-14 19:26:39 -05:00
Daniel Nephin
1bfbba36b2
Ensure that the config output by config command never contains python objects.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 18:33:58 -05:00
Daniel Nephin
3021ee12fe
Fix `config` command to print the new sections of the config
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 18:28:17 -05:00
Daniel Nephin
0f234154c2
Remove all non-external networks on down.
...
Also moves the shutdown test fixtures to be a more general v2-full fixture.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 18:28:17 -05:00
Daniel Nephin
b98e2169e6
Error when the project name is invalid for the image name.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 18:25:23 -05:00
Daniel Nephin
b689c4a218
Move service validation to validate_service().
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 18:25:22 -05:00
Joffrey F
796d97e394
Merge pull request #2617 from gutweiler/extra-hosts-ipv6
...
Extra hosts ipv6
2016-01-14 15:19:12 -08:00
Aanand Prasad
47e53b49c2
Merge pull request #2653 from shin-/Runscope-build-args
...
Support for build arguments
2016-01-14 23:13:54 +00:00
Joffrey F
1ae57d92d4
Remove duplicate functions
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-14 14:39:06 -08:00
Clemens Gutweiler
ce9f2681a2
Fixes #1422 : ipv6 addr contains colons, so we split only by the first char.
...
Signed-off-by: Clemens Gutweiler <cg@vioma.de>
2016-01-14 22:26:35 +01:00
Joffrey F
13063a96cb
Fix handling of service.dockerfile key
...
Made invalid in v2 format
Doesn't break build config anymore
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-14 12:15:37 -08:00
Garrett Heel
9cfa71ceee
Add support for build arguments
...
Allows 'build' configuration option to be specified as an
object and adds support for build args.
Signed-off-by: Garrett Heel <garrettheel@gmail.com>
2016-01-14 12:14:56 -08:00
Daniel Nephin
79df2ebe1b
Support variable interpolation for volumes and networks sections.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 14:04:57 -05:00
Aanand Prasad
d98b64f6e7
Remove duplicated logic from initialize_networks()
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:09:45 +00:00
Aanand Prasad
4e61377c6d
Move get_networks() out of Project class
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:01:44 +00:00
Aanand Prasad
73fbd01cfe
Support the 'external' option for networks
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:00:39 +00:00
Aanand Prasad
ca68c9faa4
Services can join 'bridge' or 'host'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:00:39 +00:00
Aanand Prasad
e75629392d
Don't join the bridge network by default in v2
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 18:00:39 +00:00
Aanand Prasad
3eafdbb01b
Connect services to networks with the 'networks' key
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 17:59:37 +00:00
Aanand Prasad
35e347cf92
Disable the use of 'net' in v2
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 17:59:37 +00:00
Aanand Prasad
69ed5f9c48
Specify networks in Compose file
...
There's not yet a proper way for services to join networks
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-14 17:59:36 +00:00
Aanand Prasad
8fca4f1628
Merge pull request #2649 from dnephin/make_volumes_from_more_explicit
...
Make volumes from more explicit in V2 config format
2016-01-14 17:15:27 +00:00
Daniel Nephin
172b955d79
Merge pull request #2646 from dnephin/docker_compose_down
...
docker-compose down
2016-01-14 11:59:02 -05:00
Daniel Nephin
b76dc1e05e
Require volumes_from a container to be explicit in V2 config.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 11:45:16 -05:00
Daniel Nephin
c3968a439f
Refactor config loading to move version check into ConfigFile.
...
Adds the cached_property package.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 11:45:15 -05:00
Daniel Nephin
de949284f5
Refactor config loading for handling volumes_from in v2.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 11:43:47 -05:00
Aanand Prasad
dbe04a70f0
Merge pull request #2655 from shin-/updated_volume_definition
...
Properly validate volume definition
2016-01-14 16:37:39 +00:00
Daniel Nephin
c64af0a459
Add an acceptance test and docs for the down subcommand
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 11:11:08 -05:00
Daniel Nephin
c8ed156806
Adding docker-compose down
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-14 10:59:53 -05:00
Aanand Prasad
18df1e170d
Merge pull request #2625 from kojiromike/allow-list-entrypoints
...
Allow Entrypoints to be Lists
2016-01-14 12:48:13 +00:00
Aanand Prasad
7733600262
Merge pull request #2508 from jstewmon/stop_signal
...
add support for stop_signal to compose file
2016-01-14 12:46:04 +00:00
Joffrey F
e41e6c1241
Properly validate volume definition
...
Test valid empty volume definitions
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-13 18:22:29 -08:00
Joffrey F
153185eadb
Merge pull request #2647 from shin-/preexisting_volume_detection_rb1
...
Support for external volumes
2016-01-13 17:02:36 -08:00
Michael A. Smith
59a4ab9634
Allow Entrypoints to be Lists
...
Signed-off-by: Michael A. Smith <msmith3@ebay.com>
2016-01-13 17:45:56 -05:00
Joffrey F
e76b2679eb
external volume disallows other config keys
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-13 14:12:03 -08:00
Joffrey F
c260eb910b
Merge pull request #2629 from dbonev/2611-support-port-range-in-compose
...
Port range in exposed ports
2016-01-13 13:09:22 -08:00
Aanand Prasad
3aba5bb67e
Merge pull request #2620 from dbonev/2607-ulimits-not-merged-in-extended-services
...
Ulimits are now merged into extended services
2016-01-13 21:05:38 +00:00
Joffrey F
d601199eb5
Normalize external_name
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-13 12:07:08 -08:00
Joffrey F
8616b2de51
Update error message when external volume is missing
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-13 11:23:06 -08:00
Evgeniy Dobrohvalov
bf48a781db
Add flag for stops all containers if any container was stopped.
...
Signed-off-by: Evgeniy Dobrohvalov <scipetr@gmail.com>
2016-01-13 13:12:09 +03:00
Joffrey F
9cb58b796e
Implement ability to specify external volumes
...
External volumes are created and managed by the user.
They are not namespaced.
They are expected to exist at the beginning of the up phase.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-12 16:53:49 -08:00
Joffrey F
05935b5e54
Don't recreate pre-existing volumes.
...
During the initialize_volumes phase, if a volume using the
non-namespaced name already exists, don't create the namespaced
equivalent.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-12 15:42:42 -08:00
Jonathan Stewmon
5d8c2d3cec
add support for stop_signal to compose file
...
Signed-off-by: Jonathan Stewmon <jstewmon@rmn.com>
2016-01-12 17:21:49 -06:00
Dimitar Bonev
3a46abd17f
Allowed port range in exposed ports
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-01-13 00:13:04 +02:00
Dimitar Bonev
2f07e2ac36
Ulimits are now merged into extended services
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-01-12 23:59:23 +02:00
Aanand Prasad
70cce961a8
Don't allow links or external_links in v2 files
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-12 21:29:45 +00:00
Aanand Prasad
9e17cff0ef
Refactor API version switching logic
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-12 21:29:45 +00:00
Aanand Prasad
a027a0079c
Use networking for version 2 Compose files
...
- Remove --x-networking and --x-network-driver
- There's now no way to set a network driver - this will be added back
with the 'networks' key
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-12 21:29:40 +00:00
Aanand Prasad
1a66543461
Make the default network name '{project name}_default'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2016-01-12 21:08:28 +00:00
Daniel Nephin
e98ab0e534
Allow both image and build together.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-12 14:10:00 -05:00
Daniel Nephin
ed4db542d6
Fix pep8 errors from the new pep8 release.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-12 14:02:30 -05:00
Daniel Nephin
12b5405420
Fix pre-commit on master.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-12 13:27:18 -05:00
Daniel Nephin
304a44aeab
Merge pull request #2585 from dnephin/short_signal_handlers
...
Fix signal handlers by moving shutdown logic out of handler
2016-01-12 12:55:53 -05:00
Aanand Prasad
52e50a9d9a
Merge pull request #2626 from shin-/dbonev-2503-move-logging-config-under-separate-key
...
Move logging config under separate key in v2 compose files
2016-01-12 15:21:10 +00:00
Aanand Prasad
063a25ae7d
Merge pull request #2392 from dnephin/docker_compose_events
...
docker-compose events
2016-01-12 11:45:27 +00:00
Joffrey F
46a474ecd9
Move v1-v2 config normalization to separate function.
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-11 15:53:28 -08:00
Joffrey F
c32991a8d4
Remove superfluous service code
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-11 15:39:59 -08:00
Daniel Nephin
d3cd038b84
Update event field names to match the new API fields.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-11 11:51:17 -05:00
Joffrey F
46585fb8e1
Support legacy logging options format
...
Additional test for legacy compose file.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-08 14:37:07 -08:00
Daniel Nephin
fc57fc1dc1
Merge pull request #2609 from dnephin/dont_warn_on_container_volume
...
Don't warn when the container volume is a compose option
2016-01-08 17:18:02 -05:00
Daniel Nephin
ab98c70dd1
Merge pull request #2612 from dnephin/merge_extends_from_multiple_files
...
Fix extends with multiple files
2016-01-08 17:17:41 -05:00
Joffrey F
21aae13e77
Move logging config changes to v2 spec
...
Reorganize JSON schemas
Update fixtures
Update service validation function
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-08 13:21:45 -08:00
Daniel Nephin
d1d3969661
Add docker-compose event
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-08 13:43:30 -05:00
Dimitar Bonev
ed5f7bd394
log_driver and log_opt moved to logging key.
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2016-01-08 01:54:45 +02:00
Daniel Nephin
bf1552da79
Use json to encode invalid values in configuration errors so that the user sees a proper repr of the value.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-07 13:09:24 -05:00
Daniel Nephin
475a091768
Update pre-commit config to enforace that future imports exist in all files.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-07 13:09:03 -05:00
Daniel Nephin
c7b71422c0
Fix extends with multiple files.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-06 13:30:40 -05:00
Joffrey F
a7689f3da8
Handle volume driver change error in config.
...
Assume version=1 if file is empty in get_config_version
Empty files are invalid anyway, so this simplifies the algorithm
somewhat.
https://github.com/docker/compose/pull/2421#discussion_r47223144
Don't leak version considerations in interpolation/service validation
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:22:13 -08:00
Joffrey F
f3a9533dc0
version no longer optional arg for process_config_file
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:21:54 -08:00
Joffrey F
ec5111f1c2
Volumes are now prefixed with the project name
...
When created through the compose file, volumes are prefixed
with the name of the project they belong to + underscore,
similarly to how containers are currently handled.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:21:53 -08:00
Joffrey F
ecef5d37a7
Add v2 configuration tests
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:21:53 -08:00
Joffrey F
abe145bbe7
Update config resolution to always use explicit version numbers
...
Also includes several bugfixes for resolution and validation.
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:09:39 -08:00
Joffrey F
b4be7b870f
Add support for declaring named volumes in compose files
...
* Bump default API version to 1.21 (required for named volume management)
* Introduce new, versioned compose file format while maintaining support
for current (legacy) format
* Test updates to reflect changes made to the internal API
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-01-05 15:09:39 -08:00
Daniel Nephin
4bf2f8c4f9
Fix lookup of linked containers for API version 1.20
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-05 15:09:39 -08:00
Daniel Nephin
97fe2ee40c
Don't preserve host volumes on container recreate.
...
Fixes a regression after the API changed to use Mounts.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-05 15:09:39 -08:00
Daniel Nephin
73de81b51c
Upgrade tests to use new Mounts in container inspect.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-05 15:09:39 -08:00
Daniel Nephin
ad9011ed96
Don't warn when the container volume is specified as a compose option.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-05 17:30:27 -05:00
Aanand Prasad
4017ea99fe
Merge pull request #2599 from dnephin/inject_project_name
...
Remove support for fig.yaml, FIG_FILE, and FIG_PROJECT_NAME
2016-01-05 12:29:38 +00:00
Daniel Nephin
2acc29cf1c
Remove support for fig.yaml, FIG_FILE, and FIG_PROJECT_NAME.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-01-04 15:37:21 -05:00
Daniel Nephin
778c213dfc
Fix signal handlers by moving shutdown logic out of handler.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-12-30 11:21:20 -05:00
Tomas Tomecek
adde805829
allow running compose from git
...
with:
```
$ git clone docker/compose && cd compose
$ export PYTHONPATH="$PWD:$PYTHONPATH"
$ python -m compose --help
```
Signed-off-by: Tomas Tomecek <ttomecek@redhat.com>
2015-12-26 11:03:58 +01:00
Daniel Nephin
ea8cc1c3dc
Merge pull request #2562 from thaJeztah/update-links
...
Update links
2015-12-21 08:31:39 -08:00
Aanand Prasad
a2d2915a64
Merge pull request #2547 from seguins/1125-docker-compose-create
...
Add docker-compose create command.
2015-12-21 14:20:56 +00:00
Sebastiaan van Stijn
5ed559fa0e
Update links
...
Updates some links to their new locations, and
replaces some http:// with https:// links.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2015-12-21 01:52:54 +01:00
Aanand Prasad
12a08255b5
Merge pull request #2554 from aanand/clarify-rm-behaviour
...
Clarify behaviour of 'rm'
2015-12-18 16:42:05 +00:00
Stéphane Seguin
3c76d5a467
Add docker-compose create command.
...
Closes #1125
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2015-12-18 08:53:26 +01:00
Aanand Prasad
2e9a49b4eb
Clarify behaviour of 'rm'
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-12-17 17:50:45 +00:00
Dimitar Bonev
a542041264
Added support for cpu_quota flag
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2015-12-16 21:25:30 +02:00
Dimitar Bonev
bc843d6758
Start, restart, pause and unpause exit with non-zero if nothing to do
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2015-12-15 23:11:11 +02:00
Jean Praloran
c8f266b637
add restarting status for human_readable_state
...
Signed-off-by: Jean Praloran <jeanpralo@gmail.com>
2015-12-16 08:19:28 +13:00
Dimitar Bonev
6d709caaa5
Fixes incorrect network name shown in the log when no driver is specified
...
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2015-12-11 10:14:01 +02:00
Daniel Nephin
fa3528ea25
Fix dns and dns_search when used strings and without extends.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-12-09 16:32:39 -08:00
Stéphane Seguin
999d15b225
Remove unused functions in service
...
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2015-12-08 21:11:05 +01:00
Daniel Nephin
437f3f8adb
Add docker-compose config subcommand.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-12-07 18:51:01 -08:00
Aanand Prasad
ecf2dd11f9
Merge pull request #2467 from dnephin/remove_migrate_to_labels
...
Remove migrate-to-labels.
2015-12-07 14:31:23 +00:00
Aanand Prasad
9f4e83e456
Merge pull request #2466 from dnephin/remove_insecure_ssl_warning
...
Removes the deprecated --allow-insecure-ssl flag
2015-12-07 14:29:33 +00:00
jake-low
e760c42ae0
Stop warning about ".yaml" extension
...
".yaml" is the preferred extension according to http://www.yaml.org/faq.html
Signed-off-by: jake-low <jakelow42@gmail.com>
2015-12-02 21:45:36 -08:00
Daniel Nephin
a21f9993b3
Remove migrate-to-labels.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-27 12:04:45 -05:00
Daniel Nephin
2f568984f7
Fixes #2368 , removes the deprecated --allow-insecure-ssl flag.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-27 11:52:25 -05:00
Aanand Prasad
defcf5a21f
Merge pull request #2464 from aanand/validate-expose
...
Validate `expose`
2015-11-27 14:44:55 +00:00
Aanand Prasad
ccf548b98c
Validate the 'expose' option
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-11-26 19:27:32 +00:00
Aanand Prasad
374b16843f
Fix ports validation message
...
- The `raises` kwarg to the `cls_check` decorator was being used
incorrectly (it should be an exception class, not an object).
- We need to check for `error.cause` and get the message out of the
exception object.
NB: The particular case where validation fails in the case of `ports` is
only when ranges don't match in length - no further validation is
currently performed client-side.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-11-26 18:54:30 +00:00
Aanand Prasad
d52508e2b1
Refactor ports section of fields schema
...
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-11-26 18:52:14 +00:00
Daniel Nephin
2ab3cb212a
Add integration test and docs for build with a git url.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-26 11:32:39 -05:00
Jonas Eckerström
f7239f41ef
Added support for url buid paths
...
Signed-off-by: Jonas Eckerström <jonaseck@gmail.com>
2015-11-26 11:29:07 -05:00
Daniel Nephin
e67bc2569c
Properly resolve environment from all sources.
...
Split env resolving into two phases. The first phase is to expand the paths
of env_files, which is done before merging extends. Once all files are merged
together, the final phase is to read the env_files and use them as the base
for environment variables.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-25 11:02:20 -05:00
Daniel Nephin
533f33271a
Move service sorting to config package.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:33:00 -05:00
Daniel Nephin
effa9834a5
Remove unnecessary intermediate variables in get_container_host_config.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:33:00 -05:00
Daniel Nephin
dac75b07dc
Move volume parsing to config.types module
...
This removes the last of the old service.ConfigError
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:33:00 -05:00
Daniel Nephin
efec2aae6c
Fixes #2008 - re-use list_or_dict schema for all the types
...
At the same time, moves extra_hosts validation to the config module.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:31:58 -05:00
Daniel Nephin
12b82a20ff
Move restart spec to the config.types module.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:31:58 -05:00
Daniel Nephin
068edfa313
Move parsing of volumes_from to the last step of config parsing.
...
Includes creating a new compose.config.types module for all the domain objects.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:31:58 -05:00
Daniel Nephin
c9ca5e86b0
Remove project name validation
...
project name is already normalized to a valid name before creating a service.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 13:30:54 -05:00
Aanand Prasad
665de9a494
Merge pull request #2436 from dnephin/reduce_cyclomatic_complexity
...
Reduce cyclomatic complexity
2015-11-23 17:51:54 +00:00
Daniel Nephin
b4edf0c454
Move parallel_execute to a new module.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-23 11:34:48 -05:00
Aanand Prasad
aafacd3495
Merge pull request #2418 from dnephin/fix_env_with_extends
...
Fix env_file and environment when used with extends
2015-11-23 14:48:04 +00:00
Daniel Nephin
64447879d2
Reduce complexity of merge_service_dicts
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-20 17:09:55 -05:00
Daniel Nephin
d1adbb9b25
Refactor parallel_execute.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-20 17:09:51 -05:00
Daniel Nephin
c4096525c2
Merge pull request #2364 from dnephin/handle_signals_properly
...
Handle SIGTERM/SIGINT properly for up and run
2015-11-20 11:58:04 -05:00
Daniel Nephin
8bc84c74e7
Merge pull request #2417 from dnephin/inlude_git_sha_in_version
...
Add the git sha to version output
2015-11-20 11:39:38 -05:00
Daniel Nephin
331450dace
Merge pull request #2390 from dnephin/fix_extra_warnings_on_masked_volumes
...
Fix extra warnings on masked volumes
2015-11-20 11:37:54 -05:00
Daniel Nephin
91fb6156c6
Merge pull request #2393 from seguins/1814-restart-stopped-containers
...
Fix restart with stopped containers.
2015-11-20 11:35:24 -05:00
Daniel Nephin
1e8f76767f
Fix env_file and environment when used with extends.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-18 16:07:11 -05:00
Daniel Nephin
c78c32c2e8
Fixes #2398 - the build progress stream can contain empty json objects.
...
Previously these empty objects would hit a bug in splitting objects causing it crash.
With this fix the empty objects are returned properly.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-18 16:04:41 -05:00
Daniel Nephin
d4b9845201
Add the git sha to version output
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-18 13:21:14 -05:00
Stéphane Seguin
61f91ebff7
Fix restart with stopped containers.
...
Fixes #1814
Signed-off-by: Stéphane Seguin <stephseguin93@gmail.com>
2015-11-14 12:23:23 +01:00
Daniel Nephin
e1308a8329
Fix extra warnings on masked volumes.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-13 10:49:17 -05:00
Daniel Nephin
6236bb0019
Handle both SIGINT and SIGTERM for docker-compose run.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 17:41:44 -05:00
Daniel Nephin
ea4230e7a2
Handle both SIGINT and SIGTERM for docker-compose up.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 17:41:44 -05:00
Daniel Nephin
9f6a5a964a
Merge pull request #2355 from dnephin/refactor_handle_error
...
Refactor process_error and include a filename as part of the validation error messages
2015-11-12 15:01:32 -05:00
Daniel Nephin
9c305ac10f
Remove name field from the list of ALLOWED_KEYS
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 13:26:13 -05:00
Daniel Nephin
589755d034
Inclide the filename in validation errors.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 12:44:45 -05:00
Daniel Nephin
fa96484d28
Refactor process_errors into smaller functions
...
So that it passed new max-complexity requirement
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 12:44:24 -05:00
Daniel Nephin
f7d8087694
Add ids to config schemas
...
Also enforce a max complexity for functions and add some new tests for config.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-12 12:40:36 -05:00
Joffrey F
0a35fd93cd
Merge pull request #2373 from shin-/2370-env_vars_with_dashes
...
Allow dashes in environment variable names
2015-11-11 13:20:22 -08:00
Joffrey F
513dfda218
Allow dashes in environment variable names
...
See http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap08.html
Environment variable names used by the utilities in the Shell and
Utilities volume of POSIX.1-2008 consist solely of uppercase letters,
digits, and the <underscore> ( '_' ) from the characters defined in
Portable Character Set and do not begin with a digit. Other characters may
be permitted by an implementation; applications shall tolerate the
presence of such names.
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-11 12:45:02 -08:00
Daniel Nephin
a746d673b1
Merge pull request #2350 from dnephin/remove_name_from_schema
...
Remove name field from the config schema
2015-11-11 15:43:03 -05:00
Daniel Nephin
76f3c9c739
Merge pull request #2349 from dnephin/validate_all_files
...
Validate all files before merging them
2015-11-11 15:27:47 -05:00
Joffrey F
c573fcc70a
Reorganize conditional branches to improve readability
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-11 11:21:24 -08:00
Yves Peter
b8b4c84573
Fixes #1490
...
progress_stream would print a lot of new lines on "docker-compose pull" if there's no tty.
Signed-off-by: Yves Peter <ypdraw@gmail.com>
2015-11-11 11:20:59 -08:00
Aanand Prasad
2063b39868
Merge pull request #2336 from dnephin/warn_on_volume_masking
...
Add a warning when the host volume in the compose file is masked by a data volume
2015-11-11 17:21:29 +00:00
Daniel Nephin
1f7faadc77
Remove name from config schema.
...
Refactors config validation of a service to use a ServiceConfig data object.
Instead of passing around a bunch of related scalars, we can use the
ServiceConfig object as a parameter to most of the service validation functions.
This allows for a fix to the config schema, where the name is a field in the
schema, but not actually in the configuration. My passing the name around as
part of the ServiceConfig object, we don't need to add it to the config options.
Fixes #2299
validate_against_service_schema() is moved from a conditional branch in
ServiceExtendsResolver() to happen as one of the last steps after all
configuration is merged. This schema only contains constraints which only need
to be true at the very end of merging.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-11 11:00:11 -05:00
Daniel Nephin
5e97b806d5
Fix a bug in ExtendsResolver where the service name of the extended service was wrong.
...
This bug can be seen by the change to the test case. When the extended service
uses a different name, the error was reported incorrectly.
By fixing this bug we can simplify self.signature and self.detect_cycles to
always use self.service_name.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-11 10:58:07 -05:00
Daniel Nephin
a92d86308f
Rename ServiceLoader to ServiceExtendsResolver
...
ServiceLoader has evolved to be not really all that related to "loading" a
service. It's responsibility is more to do with handling the `extends`
field, which is only part of loading. The class and its primary method
(make_service_dict()) were renamed to better reflect their responsibility.
As part of that change process_container_options() was removed from
make_service_dict() and renamed to process_service(). It contains logic for
handling the non-extends options.
This change allows us to remove the hacks from testcase.py and only call
the functions we need to format a service dict correctly for integration tests.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-11 10:58:07 -05:00
Daniel Nephin
98ad5a05e4
Validate additional files before merging them.
...
Consolidates all the top level config handling into `process_config_file` which
is now used for both files and merge sources.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-11 10:56:15 -05:00
Aanand Prasad
7466d14826
Merge pull request #2363 from dnephin/pr-2261
...
Rebase of PR 2261
2015-11-11 15:48:28 +00:00
Daniel Nephin
c006c6ea09
Merge pull request #2341 from dnephin/dont_create_default_network_sometimes
...
Only create the default network if at least one service needs it
2015-11-11 10:48:08 -05:00
Kevin Greene
22d90d2180
Added ulimits functionality to docker compose
...
Signed-off-by: Kevin Greene <kevin@spantree.net>
2015-11-10 14:07:04 -05:00
Daniel Nephin
a8ac6e6f93
Add a warning when the host volume config is being ignored.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-10 13:48:53 -05:00
Daniel Nephin
7d6c63d1b7
Merge pull request #2361 from dnephin/pr-2262
...
Rebase of PR 2262
2015-11-10 13:42:08 -05:00
Daniel Nephin
338bbb5063
Re-order flags in bash completion
...
and remove unnecessary variables from build command.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-10 13:11:59 -05:00
Joffrey F
133d213e78
Use exit code 1 when encountering a ReadTimeout
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-10 10:11:20 -08:00
Adrian Budau
c5c36d8b00
Added --force-rm to compose build.
...
It's a flag passed to docker build that removes the intermediate
containers left behind on fail builds.
Signed-off-by: Adrian Budau <budau.adi@gmail.com>
2015-11-10 13:05:04 -05:00
Daniel Nephin
45724fc667
Only create the default network if at least one service needs it.
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-10 12:43:55 -05:00
Aanand Prasad
0017f43d7f
Merge pull request #2339 from dnephin/recreate_deps_on_create
...
Recreate dependents when a dependency is created
2015-11-10 17:36:23 +00:00
Daniel Nephin
c8fa0a902a
Merge pull request #2331 from dnephin/flush_log_buffer_when_printing_logs
...
Flush the log stream after writing each line
2015-11-10 12:34:42 -05:00
Aanand Prasad
917b885a44
Merge pull request #2334 from dnephin/dont_set_hostname
...
Don't set the hostname to the service name with networking.
2015-11-10 17:34:02 +00:00
Daniel Nephin
b09cf86dd6
Merge pull request #2326 from dnephin/unicode_decode_error
...
Unicode decode error
2015-11-10 12:29:52 -05:00
Joffrey F
774d852f93
Merge pull request #2335 from dnephin/volumes_refactoring
...
Some small refactoring around volumes
2015-11-09 14:05:52 -08:00
Joffrey F
a1e140f5a3
Update service config_dict computation to include volumes_from mode
...
Ensure config_hash is updated when volumes_from mode is changed, and
service is recreated on next up as a result.
Signed-off-by: Joffrey F <joffrey@docker.com>
2015-11-09 13:07:26 -08:00
Aanand Prasad
1bfb710326
Fix parallel output
...
We were outputting an extra line, which in *some* cases, on *some*
terminals, was causing the output of parallel actions to get messed up.
In particular, it would happen when the terminal had just been cleared
or hadn't yet filled up with a screen's worth of text.
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
2015-11-09 17:24:21 +00:00
Daniel Nephin
7c2a16234f
Recreate dependents when a dependency is created (not just when it's recreated).
...
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2015-11-06 12:29:52 -05:00