Commit Graph

66 Commits

Author SHA1 Message Date
Vincent Demeester a0140b4ddb
Merge pull request #658 from arehman199/fix-a-number-of-typos
fix a number of minor typos
2017-10-31 15:07:51 +01:00
Abdur Rehman c3fe9d85ef fix a number of minor typos
Fix 19 typos, grammatical errors and duplicated words.

These fixes have minimal impact on the code as these are either in the
doc files or in comments inside the code files.

Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
2017-10-31 15:21:51 +05:00
Vincent Demeester 6e04da39b8
Merge pull request #654 from dnephin/pr-fix-image-rm
Fix behaviour of `rmi -f` with unexpected errors
2017-10-31 10:38:38 +01:00
Brian Goff 7ca234fe24
Merge pull request #652 from thaJeztah/move-notary
Move notary to its new location
2017-10-30 14:05:59 -04:00
Kyle Spiers 291fdcfdbe Remove extra quotes from docker trust sign
Signed-off-by: Kyle Spiers <kyle@spiers.me>
2017-10-30 10:31:21 -07:00
Daniel Nephin b900676523 Use t.Run() for tests
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-10-30 13:00:03 -04:00
Arash Deshmeh 125302cfa6 docker rm -f exits with 1 if the image was not removed
Signed-off-by: Arash Deshmeh <adeshmeh@ca.ibm.com>
2017-10-30 12:50:19 -04:00
Sebastiaan van Stijn 6cd58063fa
Move notary to its new location
The https://github.com/docker/notary repository has moved to
https://github.com/theupdateframework/notary

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-10-30 17:21:41 +01:00
Daniel Nephin 54e1378e04 Merge pull request #636 from dnephin/fix-trust-output-stream
Fix stdout and errors in image/trust
2017-10-27 11:31:01 -04:00
Daniel Nephin 4205416c9b Update code for upstream cobra
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-10-25 14:49:26 -04:00
Daniel Nephin 8f86a25029 Fix stdout and errors in image/trust
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-10-23 13:54:55 -04:00
Daniel Nephin dbd96badb6 Add nakedret linter.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-10-12 11:48:51 -04:00
Daniel Nephin e548861481 Refactor runPull to remove second GetImageReferencesAndAuth
Fix unit tests to catch the regression.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-10-10 16:32:27 -04:00
Riyaz Faizullabhoy 067fff8b03 trust: update references when pulling
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-10-10 11:19:02 -07:00
Sebastiaan van Stijn 0082310aa5
Fixes for updated dependencies
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-09-29 17:45:31 +02:00
Daniel Nephin 4203b49431 Refactor image commands to make use of the new trust struct for trusted pull
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-09-26 15:15:42 -04:00
Daniel Nephin d956386b2d Update gometalinter
The update includes bug fixes in gometalinter and updates to linters, which
discovered more linter problems.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-09-26 12:33:35 -04:00
Riyaz Faizullabhoy 67cf09cbe1 tests: move trust test to proper package
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-09-25 09:39:46 -07:00
Riyaz Faizullabhoy e5c35ab9d1 cli: introduce NotaryClient getter
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-09-25 09:38:38 -07:00
Riyaz Faizullabhoy 7c5b836ca5 trust: add Repository client interface
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-09-25 09:34:54 -07:00
Riyaz Faizullabhoy 45c102a03d trust: address review feedback, refactor to align with existing cli/command semantics
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-09-25 09:34:53 -07:00
Riyaz Faizullabhoy 5846e6e5d5 trust: update existing code for new vendoring, refactor for docker trust code sharing
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
2017-09-25 09:34:52 -07:00
Sébastien HOUZÉ 7e407610d4
Reset idPair during build to avoid cache busting
Signed-off-by: Sébastien HOUZÉ <cto@verylastroom.com>
2017-09-13 02:04:03 +02:00
Simon Ferquel a0113c3a44 updated vendoring
Signed-off-by: Simon Ferquel <simon.ferquel@docker.com>
2017-09-01 19:41:06 -04:00
Daniel Nephin 846a31aa50 Use new internal testutil.ErrorContains()
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-08-22 10:14:25 -04:00
Daniel Nephin b3f843afe2 Move internal/test package out of cli.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-08-22 10:14:25 -04:00
Daniel Nephin 75f7bfedf8 Update image command tests to use the new golden
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-08-16 14:20:36 -04:00
Daniel Nephin 3b8cf20a0c Merge pull request #436 from thaJeztah/improve-singular-plural-message
Singularize / pluralize "argument(s)" in error message
2017-08-14 11:06:25 -04:00
Sebastiaan van Stijn b9a7f35e02
Singularize / pluralize "argument(s)" in error message
The validation functions to test for the number of passed arguments did not
pluralize `argument(s)`, and used `argument(s)` in all cases.

This patch adds a simple `pluralize()` helper to improve this.

Before this change, `argument(s)` was used in all cases:

    $ docker container ls foobar
    "docker container ls" accepts no argument(s).

    $ docker network create one two
    "docker network create" requires exactly 1 argument(s).

    $ docker network connect
    "docker network connect" requires exactly 2 argument(s).

    $ docker volume create one two
    "docker volume create" requires at most 1 argument(s).

After this change, `argument(s)` is properly singularized or plurarized:

    $ docker container ls foobar
    "docker container ls" accepts no arguments.

    $ docker network create one two
    "docker network create" requires exactly 1 argument.

    $ docker network connect
    "docker network connect" requires exactly 2 arguments.

    $ docker volume create one two
    "docker volume create" requires at most 1 argument.

Test cases were updated accordingly.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-08-12 18:25:38 +02:00
Sebastiaan van Stijn f007d623a8
Add test for github.com special handling
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-08-03 17:53:42 +02:00
Darren Stahl 18c877d35c Fast fail when save directory does not exist
Signed-off-by: Darren Stahl <darst@microsoft.com>
2017-07-27 15:00:38 -07:00
Daniel Nephin 42a3800783 Update some tests to remove unnecessary buffers.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-07-11 17:52:43 -04:00
Daniel Nephin 3da0cbfdd1 Remove unnecessary use of SetConfigfile
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-07-11 14:49:30 -04:00
Daniel Nephin 69b142b52a Update FakeCli to remove duplication in tests.
Use byte buffers by default, since that is what is done most of the time.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-07-11 14:49:30 -04:00
Sebastiaan van Stijn e8080dd7e5
update tests for new image struct
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-07-04 20:34:24 -07:00
Daniel Nephin a04aa8fe28 Compress after rewriting the archive.
Write a test showing compress failure.

Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-06-29 13:18:10 -04:00
Vincent Demeester 105b21d1ab
Rename NewConfigFile to New in configfile package
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-27 16:31:38 +02:00
Daniel Nephin a3cbc70147
Move credential getting functions to the ConfigFile.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-06-27 13:46:47 +02:00
Tonis Tiigi b95638a5ac Use long running session in builder
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>

Add incremental context send support

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-06-26 16:30:01 -07:00
Brian Goff 2bfac7fcda Merge pull request #176 from dnephin/new-lint
New linters
2017-06-20 16:47:45 -07:00
Dave Tucker 35f1e301b5 Allow Proxy Configuration in config.json
This commit modifies config.json to allow for any proxies allowed in
build-args to be configured. These values will then be used
by default as build-args in docker build.

Signed-off-by: Dave Tucker <dt@docker.com>
2017-06-20 09:51:41 +01:00
Daniel Nephin 01e1e58ada Add unused linter.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-06-14 16:54:27 -07:00
Daniel Nephin 676b71eaaa Fix some problems with image remove force.
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-06-13 12:12:54 -07:00
Vincent Demeester dd924ebf4f
Fix remove_test output duplication
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-13 14:02:56 +02:00
Vincent Demeester ecc8e0a204 Merge pull request #160 from e11137/master
fixes #46 Always exit 0 when remove image with force option
2017-06-13 14:02:02 +02:00
Daniel Nephin 0310de5213 Move IsArchive and HeaderSize to build/context
Previously these were in docker/docker/pkg/archive, but unused

Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-06-08 16:08:11 -04:00
Rogelio Canedo 5c8d702af5 Always exit whith -1 when remove image with force option
Signed-off-by: Rogelio Canedo <rcanedo@mappy.priv>
2017-06-08 20:15:37 +02:00
Vincent Demeester 44ac80881f
Update vendoring of docker/docker
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-06-06 00:23:21 +02:00
Vincent Demeester d7f6563efc
Update cli imports to using local package
Also, rename a bunch of variable to not *shadow* the `opts` package
name.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2017-05-15 14:45:19 +02:00
Daniel Nephin 37ccc00d0e Add interfacer linter
Signed-off-by: Daniel Nephin <dnephin@docker.com>
2017-05-08 15:57:50 -04:00