Commit Graph

21 Commits

Author SHA1 Message Date
Kir Kolyshkin 83363fb2d4 integration: use %s for check.Commentf()
It is wrong to pass an arbitrary string to a function expecting
%-style formatting. One solution would be to replace any % with %%,
but it's easier to just do what this patch does.

Generated with:

for f in $(git grep -l 'check.Commentf(out)'); do \
	sed -i -e 's/check\.Commentf(out)/check.Commentf("%s", out)/g' $f; \
done

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2018-08-14 10:45:39 +03:00
Yong Tang 9247e09944 Fix issue of ExitCode and PID not show up in Task.Status.ContainerStatus
This fix tries to address the issue raised in 36139 where
ExitCode and PID does not show up in Task.Status.ContainerStatus

The issue was caused by `json:",omitempty"` in PID and ExitCode
which interprate 0 as null.

This is confusion as ExitCode 0 does have a meaning.

This fix removes  `json:",omitempty"` in ExitCode and PID,
but changes ContainerStatus to pointer so that ContainerStatus
does not show up at all if no content. If ContainerStatus
does have a content, then ExitCode and PID will show up (even if
they are 0).

This fix fixes 36139.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2018-01-31 15:35:19 +00:00
Eli Uriegas e5b3ebbc64 Explicitly add --detach to service CLI calls
The behavior of service (create/update/scale) was changed in a recent PR
to docker/cli. This commit serves to remedy test failures experienced
when attempting to use service calls.

Should not affect current behavior.

Signed-off-by: Eli Uriegas <eli.uriegas@docker.com>
2017-09-27 16:17:55 -07:00
Madhu Venugopal 38c1553150 Service alias should not be copied to task alias
If a service alias is copied to task, then the DNS resolution on the
service name will resolve to service VIP and all of Task-IPs and that
will break the concept of vip based load-balancing resulting in all the
dns-rr caching issues.

This is a regression introduced in #33130

Signed-off-by: Madhu Venugopal <madhu@docker.com>
2017-06-07 13:05:15 -07:00
Aaron Lehmann d012569b78 Update CLI commit hash
Since this new version of the CLI resolves image digests for swarm
services by default, and we do not want integration tests to talk to
Docker Hub, update CLI tests to suppress this behavior.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2017-05-18 12:23:28 -07:00
Aaron Lehmann d2c5b6ee9f Add integration test coverage for configs
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2017-05-11 10:18:44 -07:00
Aaron Lehmann 0da7bd0314 Extend test coverage of secrets
Actually look inside the container to see if the secret data is present
and correct. Test absolute paths, relative paths, and just a basename.
Test the scenario where a service references the same secret under
different targets.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2017-05-10 10:23:10 -07:00
Evan Hazlett 67d282a5c9 support custom paths for secrets
This adds support to specify custom container paths for secrets.

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2017-05-10 10:23:07 -07:00
Aaron Lehmann 330a003533 Synchronous service create and service update
Change "service create" and "service update" to wait until the creation
or update finishes, when --detach=false is specified. Show progress bars
for the overall operation and for each individual task (when there are a
small enough number of tasks), unless "-q" / "--quiet" is specified.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
2017-04-03 09:46:01 -07:00
liker12134 2333b39b37 fixed:go vetting warning unkeyed fields
Signed-off-by: Aaron.L.Xu <liker.xu@foxmail.com>
2017-03-20 16:30:01 +08:00
Vincent Demeester 33968e6c7d
Remove pkg/integration and move it to testutil or integration-cli
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-12-30 18:26:34 +01:00
Vincent Demeester 48de91a33f Extract daemon to its own package
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2016-12-09 22:26:42 +01:00
Brian Goff a5b3649bfa Fix issue where TmpfsOptions are not sent to swarm
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2016-12-02 11:43:47 -05:00
Brian Goff 821aeb6a6f Use container Mounts API for Swarm containers.
Instead of converting nicely typed service mounts into untyped `Binds`
when creating containers, use the new `Mounts` API which is a 1-1
mapping between service mounts and container mounts.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2016-11-22 13:23:51 -05:00
Evan Hazlett bebd472e40 do not force target type for secret references
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>

use secret store interface instead of embedded secret data into container

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2016-11-17 15:49:02 -05:00
Evan Hazlett a257f674ba secrets: support simple syntax --secret foo
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2016-11-09 14:27:45 -05:00
Evan Hazlett 2adbdcdf5a secrets: use explicit format when using secrets
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2016-11-09 14:27:44 -05:00
Evan Hazlett ca6b653551 update tests for service create and update
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2016-11-09 14:27:44 -05:00
Evan Hazlett 76b33fdb99 secrets: add service create and update integration tests
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2016-11-09 14:27:44 -05:00
Michael Crosby 91e197d614 Add engine-api types to docker
This moves the types for the `engine-api` repo to the existing types
package.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-09-07 11:05:58 -07:00
Daniel Nephin 0ec20a3c01 Remove hack from test name.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2016-07-28 20:12:36 -04:00