Skip to content

Conversation

alexeykazakov
Copy link

Fixes #83

  1. New contexts_list tool for listing all available contexts in the cubeconfig.
  2. All tools now have an optional contex param. If not specified then the default context is used.

Here is an example of context_list result:

Available Kubernetes contexts (3 total, current: cluster-1):

Format: [*] CONTEXT_NAME -> CLUSTER_SERVER_URL
        (* indicates the current active context)

Contexts:
─────────
* cluter-1 -> https://api.cluster-1.com:443
  cluter-2 -> https://api.cluster-2.com:443
  cluter-3 -> https://api.cluster-2.com:443
─────────

Usage:
To use a specific context with any tool, add the 'context' parameter:
Example: {"name": "pods_list", "arguments": {"context": "cluster-1"}}`

@iamsudip
Copy link
Contributor

This is a useful tool, waiting for it to get merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support for multiple contexts and switching between them

2 participants