github.com/khulnasoft/cli@v0.0.0-20240402070845-01bcad7beefa/docs/reference/commandline/context_update.md (about)

     1  # context update
     2  
     3  <!---MARKER_GEN_START-->
     4  Update a context
     5  
     6  Docker endpoint config:
     7  
     8  NAME                DESCRIPTION
     9  from                Copy named context's Docker endpoint configuration
    10  host                Docker endpoint on which to connect
    11  ca                  Trust certs signed only by this CA
    12  cert                Path to TLS certificate file
    13  key                 Path to TLS key file
    14  skip-tls-verify     Skip TLS certificate validation
    15  
    16  Example:
    17  
    18  $ docker context update my-context --description "some description" --docker "host=tcp://myserver:2376,ca=~/ca-file,cert=~/cert-file,key=~/key-file"
    19  
    20  
    21  ### Options
    22  
    23  | Name            | Type             | Default | Description                |
    24  |:----------------|:-----------------|:--------|:---------------------------|
    25  | `--description` | `string`         |         | Description of the context |
    26  | `--docker`      | `stringToString` |         | set the docker endpoint    |
    27  
    28  
    29  <!---MARKER_GEN_END-->
    30  
    31  ## Description
    32  
    33  Updates an existing `context`.
    34  See [context create](context_create.md).
    35  
    36  ## Examples
    37  
    38  ### Update an existing context
    39  
    40  ```console
    41  $ docker context update \
    42      --description "some description" \
    43      --docker "host=tcp://myserver:2376,ca=~/ca-file,cert=~/cert-file,key=~/key-file" \
    44      my-context
    45  ```