Files
docker-cli/cli/command
Sebastiaan van Stijn 3b7235edca cli/command: initialize client and load content lazily
This allows commands that don't require a client connection (such as `context use`)
to be functional, but still produces an error when trying to run a command that
needs to connect with the API;

    mkdir -p ~/.docker/ && echo '{"currentContext":"nosuchcontext"}' >  ~/.docker/config.json
    docker version
    Failed to initialize: unable to resolve docker endpoint: load context "nosuchcontext": context does not exist: open /root/.docker/contexts/meta/8bfef2a74c7d06add4bf4c73b0af97d9f79c76fe151ae0e18b9d7e57104c149b/meta.json: no such file or directory

    docker context use default
    default
    Current context is now "default"

    docker version
    Client:
     Version:           22.06.0-dev
     API version:       1.42
     ...

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2022-11-28 16:52:02 +01:00
..
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2022-09-30 11:59:11 +02:00
2017-09-01 19:41:06 -04:00
2022-09-30 11:59:11 +02:00