Commit Graph

183 Commits

Author SHA1 Message Date
Joffrey F 454b063fed Keep no-ansi parameter in the CLI scope
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-08-09 19:00:23 -07:00
Joffrey F 9502408ff0 Fix test issues with Engine 17.07 RC1
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-07-26 17:33:02 -07:00
Joffrey F 6a4adb64f9 Some more test adjustments for Swarm support
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-07-20 16:39:03 -07:00
Joffrey F 8f0ef26a73 Improved version comparisons throughout the codebase
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-07-11 17:40:53 -07:00
Joffrey F 2b7ed24bc0 Fix override volume merging + add acceptance test
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-07-03 17:24:32 -07:00
Joffrey F 259b96748c Add support for service:name pid config
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-07-03 16:15:20 -07:00
Joffrey F 7a4c328c41 Rewriting tests to be UCP/Swarm compatible
- Event may contain more information in some cases.
  Don't assume order or format
- Don't assume ports are always exposed on 0.0.0.0 by default
- Absence of HostConfig in a create payload sometimes causes an error at the
  engine level
- In Swarm, volume names are prefixed by "<node_name>/"
- When testing against Swarm, the default network driver is overlay
- Ensure custom test networks are always attachable
- Handle Swarm network names
- Some params moved to host config in recent (1.21+) version
- Conditional test skips for Swarm environments

Signed-off-by: Joffrey F <joffrey@docker.com>
2017-06-14 16:17:15 -07:00
Joel Barciauskas e9b6cc23fc Add --quiet parameter to docker-compose pull, using existing silent flag
Signed-off-by: Joel Barciauskas <barciajo@gmail.com>
2017-06-14 14:53:13 -07:00
Joffrey F 8512b33e24 Remedy test failures
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-06-06 11:50:09 -07:00
Joffrey F 972fe65830 Merge pull request #4860 from shin-/4845-rm-stop
Fix improper use of project.stop
2017-05-23 15:08:13 -07:00
Joffrey F 244209814b Fix improper use of project.stop
Add some better test coverage for rm --stop

Signed-off-by: Joffrey F <joffrey@docker.com>
2017-05-23 12:38:54 -07:00
Eli Atzaba 0d0c0454e9 Raise exception when override.yaml & override.yml coexist
Signed-off-by: Eli Atzaba <eliat123@gmail.com>
2017-05-23 12:09:19 -07:00
Eli Atzaba 9334f29898 Fix for yaml extention does not work with override file
Signed-off-by: Eli Atzaba <eliat123@gmail.com>
2017-05-23 12:09:19 -07:00
Joffrey F 59a4f554b9 Prevent dependencies rescaling when executing `docker-compose run`
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-05-12 17:39:56 -07:00
Joffrey F 2ba4e5e8ec Prevent `docker-compose scale` to be used with a v2.2 config file
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-04-21 11:42:18 -07:00
Joffrey F afb2b6c51c Properly relay errors in execute_convergence_plan
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-04-18 12:53:43 -07:00
Joffrey F 78ee612333 Implement --scale option on up command, allow scale config in v2.2 format
docker-compose scale modified to reuse code between up and scale

Signed-off-by: Joffrey F <joffrey@docker.com>
2017-04-17 19:51:48 -07:00
Joffrey F c817dedef7 Repair bad imports
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-04-14 14:31:30 -07:00
Joffrey F eab1ee0eaf Support 'nocopy' mode for expanded volume syntax
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-23 15:17:23 -07:00
Joffrey F 69d0c0e3a0 Add support for expanded mount/volume notation
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-17 20:42:59 -07:00
Dimitar Bonev 707210ae95 Ability to change working directory via a CLI flag
Signed-off-by: Dimitar Bonev <dimitar.bonev@gmail.com>
2017-03-08 14:42:14 -08:00
Joffrey F e344fe9a9f Merge pull request #4566 from shin-/eddwardo-run-v
Add --volumes flag to docker-compose run
2017-03-07 15:22:51 -08:00
Joffrey F 01fa147183 Merge pull request #4040 from rawkode/feature/allow-running-containers-to-be-deleted
Allowing running containers to be rm'd by stop flag
2017-03-06 18:34:19 -08:00
Joffrey F 0167aba2b7 Merge pull request #4541 from shin-/4502-expanded-port-syntax
Add support for expanded port syntax in 3.1 format
2017-03-06 18:32:52 -08:00
Joffrey F d75726db21 Merge pull request #4561 from shin-/JesusTinoco-3501-add-image-command-option
Add images command
2017-03-06 18:28:34 -08:00
Joffrey F bf7c2bc0f8 Use create_host_file in run -v tests to ensure file availability
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-06 18:13:16 -08:00
Joffrey F 8f8678987b Improve readability of code and output for the images command
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-06 15:56:41 -08:00
Joffrey F 83728d2bcc Do not add mode in volume representation if it's not a host binding
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-06 14:43:29 -08:00
Piotr Szymanski 83388ec31a enable -v flag for docker-compose run command
Give user ability to attach volumes while running containers with
docker-compose run command. Example is given in the test implementation,
command is compatible with the one provided by docker engine.

Signed-off-by: Piotr Szymanski <skyleton@gmail.com>
2017-03-02 16:50:24 -08:00
stefan 11329e779b added failing test that ensures that named volume will not be printed with a mode suffix
Signed-off-by: stefan <think@hotmail.de>
2017-03-02 15:26:40 -08:00
Jesus Tinoco 90beeaf21c 3501 - Remove a test and fix other
Signed-off-by: Jesus Rodriguez Tinoco <jesus.rodriguez.tinoco@gmail.com>
2017-03-02 15:00:55 -08:00
Jesus Tinoco 33f510b340 3501 - Add a new command option (images)
Signed-off-by: Jesus Rodriguez Tinoco <jesus.rodriguez.tinoco@gmail.com>
2017-03-02 15:00:55 -08:00
Joffrey F 6986a994a8 Merge branch 'forward-exit' of https://github.com/TheClimateCorporation/compose into TheClimateCorporation-forward-exit
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-01 18:04:48 -08:00
kbroadwater 6c3641fdb7 Returing 1 when a container exits with a non-zero exit code with --abort-on-container-exit is set. Signed-off-by: Kevin Broadwater <kevin.broadwater@gmail.com>
Catching the first container to exit Signed-off-by: Kevin Broadwater <kevin.broadwater@gmail.com>

Addressing feedback and fixing tests Signed-off-by: Kevin Broadwater <kevin.broadwater@gmail.com>

Adding break and removing extra fixture files Signed-off-by: Kevin Broadwater <kevin.broadwater@gmail.com>

Moving break Signed-off-by: Kevin Broadwater <kevin.broadwater@gmail.com>
2017-03-01 17:08:26 -08:00
Joffrey F 1a77a7fd44 Merge pull request #3756 from nkovacs/2419-run-rm-volumes
Remove anonymous volumes when using run --rm.
2017-03-01 16:38:46 -08:00
Joffrey F eca3146c9c Merge pull request #3617 from dguo/help-nonexistent-command
Handle giving help a nonexistent command
2017-03-01 16:31:37 -08:00
Joffrey F 9f8e01fa94 Merge pull request #3543 from milin/master
Replace assertEquals with assertEqual in unittests since the former is getting dep…
2017-03-01 16:27:36 -08:00
Evan Shaw d67261f26e Add --volumes flag to config command
Closes #3609

Signed-off-by: Evan Shaw <evan@vendhq.com>
2017-03-02 10:03:31 +13:00
Joffrey F 11788ef0ff Add support for expanded port syntax in 3.1 format
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-03-01 12:10:51 -08:00
David McKay 1f9fb27456 Allowing running containers to be rm'd by stop flag
Signed-off-by: David McKay <david@rawkode.com>
2017-03-01 10:33:23 +00:00
Nathan J. Mehl cffb76d4d9 Address comments
- set flag name to `--exit-code-from` (and rename some variable,
  function and test names to match)
- force cascade_stop to true when exit-code-from flag is set
- use lambda in filter statement
- check that selected container name is in the project before running
- remove fancy parsing of service name to container mappings: if there
  are multiple containers in a service, return the first nonzero exit
  value if any
- flake8 changes

Signed-off-by: Nathan J. Mehl <n@climate.com>
2017-02-27 09:51:03 -08:00
Nathan J. Mehl a73190e1cc Add support for returning the exit value of a specific container
Current best practice for using docker-compose as a tool for continuous
integration requires fragile shell pipelines to query the exit status
of composed containers, e.g.:

http://stackoverflow.com/questions/29568352/using-docker-compose-with-ci-how-to-deal-with-exit-codes-and-daemonized-linked
http://blog.ministryofprogramming.com/docker-compose-and-exit-codes/

This PR adds a `--forward-exitval <container>` flag that allows
`docker-compose up` to return the exit value of a specified container.
The container may optionally have a number specified (foo_2) otherwise
the first is defaulted to.

Signed-off-by: Nathan J. Mehl <n@climate.com>
2017-02-27 08:37:11 -08:00
Aaron.L.Xu d20e3f3342 function-name-modification for tests/*
Signed-off-by: Aaron.L.Xu <likexu@harmonycloud.cn>
2017-02-16 15:25:20 +08:00
Peter Urda a67500ee57
Added `top` to `docker-compose` to display running processes.
This commit allows `docker-compose` to access `top` for containers
much like running `docker top` directly on a given container.

This commit includes:

* `docker-compose` CLI changes to expose `top`
* Completions for `bash` and `zsh`
* Required testing for the new `top` command

Signed-off-by: Peter Urda <peter.urda@gmail.com>
2017-02-01 15:42:30 -08:00
Joffrey F e10d1140b9 Convert time data back to string values when serializing config
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-01-26 11:59:22 -08:00
Joffrey F 9a0962dacb Merge pull request #4361 from shin-/4348-serialize-ext-volumes
Remove external_name from volume def in config output
2017-01-19 17:41:08 -08:00
Joffrey F d83d31889e Remove external_name from volume def in config output
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-01-19 16:05:13 -08:00
Joffrey F 5c2165eaaf Fix volume definition in v3 schema
Signed-off-by: Joffrey F <joffrey@docker.com>
2017-01-19 15:41:31 -08:00
Joffrey F ba47fb99ba Add default labels to networks and volumes created by Compose
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-12-19 20:43:35 -08:00
Joffrey F fb165d9c15 Add v3_only marker to healthcheck test
Signed-off-by: Joffrey F <joffrey@docker.com>
2016-12-16 12:21:59 -08:00