Anca Iordache
2dfd85e30e
Use docker context interface from docker-py
...
Signed-off-by: Anca Iordache <anca.iordache@docker.com>
2020-02-06 12:01:37 +01:00
Ulysses Souza
9f5f8b4757
Remove `None` entries on execute command
...
Signed-off-by: Ulysses Souza <ulyssessouza@gmail.com>
2020-01-30 19:26:33 +01:00
Ben Thorner
a6b602d086
Support attaching to dependencies on up
...
When using the 'up' command, only services listed as arguments are
attached to, which can be very different to the 'no argument' case
if a service has many and deep dependencies:
- It's not clear when dependencies have failed to start. Have to run
'compose ps' separately to find out.
- It's not clear when dependencies are erroring. Have to run 'compose
logs' separately to find out.
With a simple setup, it's possible to work around theses issue by
using the 'up' command without arguments. But when there are lots of
'top-level' services, with common dependencies, in a single config,
using 'up' without arguments isn't practical due to resource limits
and the sheer volume of output from other services.
This introduces a new '--attach-dependencies' flag to optionally attach
dependent containers as part of the 'up' command. This makes their logs
visible in the output, alongside the listed services. It also means we
benefit from the '--abort-on-container-exit' behaviour when dependencies
fail to start, giving more visibility of the failure.
Signed-off-by: Ben Thorner <ben.thorner@digital.cabinet-office.gov.uk>
2020-01-16 13:41:54 +00:00
Kevin Roy
093cc2c089
Allow setting compatibility options from environment
...
Signed-off-by: Kevin Roy <kiniou@gmail.com>
2020-01-13 14:53:03 +01:00
Sergey Fursov
c818bfc62c
support PyYAML up to 5.x version
...
Signed-off-by: Sergey Fursov <geyser85@gmail.com>
2020-01-09 12:30:51 +01:00
Sebastiaan van Stijn
33eeef41ab
Remove "bundle" subcommand and support for DAB files
...
Deploying stacks using the "Docker Application Bundle" (`.dab`) file
format was introduced as an experimental feature in Docker 1.13 /
17.03, but superseded by support for Docker Compose files in the CLI.
With no development being done on this feature, and no active use of the file
format, support for the DAB file format and the top-level `docker deploy` command
(hidden by default in 19.03), will be removed from the CLI, in favour of
`docker stack deploy` using compose files.
This patch removes the `docker-compose bundle` subcommand from Docker Compose,
which was used to convert compose files into DAB files (and given the above,
will no longer be needed).
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-01-08 16:42:49 +01:00
Nicolas De Loof
55c5c8e8ac
Report image we can't pull and must be built
...
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2019-11-25 15:18:27 +01:00
Ulysses Souza
a83d86e7ce
Merge pull request #7037 from ndeloof/stdin
...
config_detail.filename is None when passed by stdin
2019-11-22 15:24:43 +01:00
Nicolas De Loof
e6ec77047b
Revert "only pull images that can't build"
...
This reverts commit c6dd7da15e
.
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2019-11-21 14:37:41 +01:00
Nicolas De Loof
fe2b692547
testcase for compose file read from stdin
...
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2019-11-20 15:38:15 +01:00
Nicolas De Loof
1ca10f90fb
Fix acceptance tests
...
tty is now (correclty) reported to have 80 columns, which split service
ID in two lines
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2019-10-16 14:31:27 +02:00
aiordache
60dcf87cc0
update alpine version to 3.10.1
...
Signed-off-by: aiordache <anca.iordache@docker.com>
2019-08-20 12:10:26 +02:00
Ulysses Souza
b03889ac2a
Add integration tests regarding environment
...
This covers what was included in #6800
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-07-31 02:09:41 +02:00
Ulysses Souza
cd098e0cad
Pin test images on a non rolling tag
...
Mainly busybox:latest to the current latest which is 1.31.0-uclibc
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-07-18 11:10:37 +02:00
Djordje Lukic
c8279bc4db
Merge pull request #6738 from Inconnu08/set-optimization
...
Replace sets with set literal syntax for efficiency
2019-07-15 15:23:24 +02:00
Ulysses Souza
cacc9752a3
Pin busybox image version in tests
...
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-07-02 13:42:41 +02:00
Inconnu08
b29b6a1538
replace sets with set literal syntax for efficiency
...
Signed-off-by: Taufiq Rahman <taufiqrx8@gmail.com>
2019-05-31 20:29:09 +06:00
Ian Campbell
a89128118b
Merge pull request #6342 from collin5/b5547
...
--remove-orphans is ignored when using up --no-start
2019-05-20 15:45:24 +01:00
Ulysses Souza
8a9575bd0d
Remove remaining containers on test_build_run
...
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-05-14 19:13:21 +02:00
Ulysses Souza
f2dc923084
Avoid race condition on test
...
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-04-19 15:53:02 +02:00
Ulysses Souza
e047169315
Workaround race conditions on tests
...
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-04-17 17:59:12 +02:00
Ian Campbell
6ccbb56fec
Merge pull request #6494 from collin5/b6464
...
Only pull images that can't build `docker-compose pull`
2019-03-25 13:25:32 +00:00
Collins Abitekaniza
c6dd7da15e
only pull images that can't build
...
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
2019-03-24 01:05:30 +03:00
Ian Campbell
7bf9963cd6
Merge pull request #6547 from kudos/bugfix/scale-zero-default
...
Fix scale attribute to accept 0 as a value
2019-03-07 15:40:14 +00:00
Jonathan Cremin
087bef4f95
Add tests for compose file 'scale: 0'
...
Signed-off-by: Jonathan Cremin <jonathan@crem.in>
2019-03-06 12:57:14 +00:00
Akshit Grover
1f97a572fe
Add --quiet build flag
...
Signed-off-by: Akshit Grover <akshit.grover2016@gmail.com>
2019-03-02 13:07:23 +05:30
slowr
b09d8802ed
Added additional argument (--env-file) for docker-compose to import environment variables from a given PATH.
...
Signed-off-by: Dimitrios Mavrommatis <jim.mavrommatis@gmail.com>
2019-02-26 16:38:54 +01:00
Ulysses Souza
a35aef4953
Add --no-rm to command build
...
- When present, build does not remove
intermediate containers after a successful build.
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2019-02-20 18:09:09 +01:00
Collins Abitekaniza
c27132afad
remove stopped containers on --remove-orphans
...
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
kill orphan containers, catch APIError Exception
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
test remove orphans with --no-start
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
2019-01-25 14:28:56 +03:00
Joffrey F
2ed171cae9
Bring zero container check up in the call stack
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2019-01-10 15:48:37 -08:00
Collins Abitekaniza
325637d9d5
test image pull done
...
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
2019-01-10 15:48:37 -08:00
Joffrey F
14e7a11b3c
Merge pull request #6346 from collin5/b5469
...
Show failed services 'docker-compose start' when containers are not availabe
2018-12-10 15:39:16 -08:00
Ulysses Souza
d563a66405
Update `reorder_python_imports` version to fix Unicode problems
...
Signed-off-by: Ulysses Souza <ulysses.souza@docker.com>
2018-12-01 00:35:34 +01:00
Collins Abitekaniza
b8b6199958
refactor cli tests
...
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
2018-11-28 15:44:58 +03:00
Joffrey F
61bb1ea484
Don't append slugs to containers created by "up"
...
This change reverts the new naming convention introduced in 1.23 for service containers.
One-off containers will now use a slug instead of a sequential number as they do not
present addressability concerns and benefit from being capable of running in parallel.
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-11-27 18:58:55 -08:00
Collins Abitekaniza
05efe52ccd
test --all flag
...
Signed-off-by: Collins Abitekaniza <abtcolns@gmail.com>
2018-11-06 14:59:48 +03:00
Joffrey F
98bb68e404
Fix new flake8 errors/warnings
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-10-24 15:06:04 -07:00
Joffrey F
834acca497
Update acceptance test for image matching
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-09-20 15:48:08 -07:00
Boris HUISGEN
1b668973a2
Add acceptance test
...
Signed-off-by: Boris HUISGEN <bhuisgen@hbis.fr>
2018-09-20 15:48:08 -07:00
Joffrey F
5916639383
Preserve container numbers, add slug to prevent name collisions
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-09-12 12:07:52 -07:00
Joffrey F
4e2de3c1ff
Replace sequential container indexes with randomly generated IDs
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-09-11 15:26:58 -07:00
Joffrey F
eb63e9f3c7
Fix --project-directory handling to apply to .env files as well
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-08-10 17:02:56 -07:00
Joffrey F
ee878aee4c
Handle missing (not built) service image in config --hash
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-08-07 20:23:21 -07:00
Joffrey F
861031b9b7
Reduce config --hash code complexity and add test
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-08-07 17:25:35 -07:00
Gil Raphaelli
89f2bfe4f3
add --parallel option to build
...
Signed-off-by: Gil Raphaelli <g@raphaelli.com>
2018-07-31 12:06:59 -04:00
Joffrey F
635c77db6c
Merge pull request #6071 from nickhiggs/6060-reattach-logger-on-restart
...
Attach logger to containers after crashing.
2018-07-25 15:20:43 -07:00
Joffrey F
e6d18b1881
Fix --exit-code-from to reflect exit code after termination by Compose
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-07-10 15:28:55 -04:00
Nicholas Higgins
28085ebee2
Attach logger to containers after crashing.
...
Fixes #6060
Signed-off-by: Nicholas Higgins <nickhiggins42@gmail.com>
2018-07-09 08:47:20 +10:00
Joffrey F
f368b4846f
Ignore attachable property on networks in compatibility mode
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-05-04 15:16:43 -07:00
Joffrey F
cbb9bff924
Support -H=host notation for interactive run/execs
...
Signed-off-by: Joffrey F <joffrey@docker.com>
2018-03-26 14:25:31 -07:00