---
title: "ezgh kubernetes token"
description: "Print a token for kubectl."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ezgh kubernetes token

{/* Generated by ezgh-cli's internal/tools/clidocs from the ezgh command tree. Don't edit: change the command's help in ezgh-cli and regenerate. */}

```sh
ezgh kubernetes token --cluster c [flags]
```

Print a short-lived token for a cluster as a kubectl ExecCredential, with your EZGH credential. kubectl runs this itself: `ezgh kubernetes update-kubeconfig` sets it up. Nothing is stored: kubectl keeps the token in memory and asks again before it expires.

Part of [`ezgh kubernetes`](/cli/reference/kubernetes).

## Flags

| Flag | Type | Default | Description |
| --- | --- | --- | --- |
| `--cluster` | string |  | the cluster |

This command also takes the [global flags](/cli/reference#global-flags).

Source: https://docs.ezghcloud.com/cli/reference/kubernetes-token/index.mdx
