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

# operator

> cpln operator — Manage the Kubernetes operator that syncs Control Plane resources with a cluster.

A Kubernetes operator for Control Plane

Refer to the [cpln operator guide](https://docs.controlplane.com/guides/cli/cpln-operator.md) for additional details.

```none theme={null}
cpln operator [SUBCOMMAND]
```

```text theme={null}
Commands:
  cpln operator install    Install the Kubernetes operator to your cluster
  cpln operator uninstall  Uninstall the Kubernetes operator from your cluster

Options:
  --help  Show help  [boolean]
```

***

#### operator install

Install the Kubernetes operator to your cluster

**Usage**

```none theme={null}
cpln operator install [OPTIONS]
```

> [!TIP]
>
> Use `--export` to review or store the Kubernetes resources before applying:
>
> ```bash theme={null}
> # Export to a file for review or GitOps
> cpln operator install \
>   --serviceaccount k8s-operator \
>   --org YOUR_ORG_NAME \
>   --export > operator-secret.yaml
>
> # Apply later
> kubectl apply -f operator-secret.yaml
> ```

> [!TIP]
>
> For production, assign the service account to a group with limited permissions:
>
> ```bash theme={null}
> cpln operator install \
>   --serviceaccount k8s-operator \
>   --serviceaccount-group operators \
>   --org YOUR_ORG_NAME
> ```

> [accordion] Reference
>
> ```text theme={null}
> Command options:
>   --serviceaccount, -s        The service account name for the operator. If the service account does not exist, a new one will be created  [required]
>   --serviceaccount-group, -g  The group to assign to the service account if it will be created.  [default: "superusers"]
>   --export                    Export the Kubernetes resources to a file instead of applying them to the cluster.  [boolean]
>
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***

#### operator uninstall

Uninstall the Kubernetes operator from your cluster

**Usage**

```none theme={null}
cpln operator uninstall [OPTIONS]
```

> [accordion] Reference
>
> ```text theme={null}
> Context options:
>   --profile  Override the profile. The default profile can be set using the `cpln profile set-default` command or by setting the CPLN_PROFILE environment variable
>   --org      Override the organization. The default organization can be set in your profile by using the `cpln profile update` command
>
> Format options:
>   --output, -o  Set the output format  [choices: "text", "json", "yaml", "json-slim", "yaml-slim", "tf", "crd", "names"]
>   --color       Colorize the output  [boolean] [default: true]
>   --ts          Timestamp format if the output format is text (e.g., --output=text)  [choices: "iso", "local", "age"]
>   --max         Maximum number of records to show. A value less than 1 will return all records.  [number] [default: 50]
>
> Request options:
>   --token         Override the authorization token
>   --endpoint      Override the API URL
>   --insecure, -k  Ignore TLS errors  [boolean]
>
> Debug options:
>   --verbose, -v  Enable verbose output to stderr  [boolean] [default: false]
>   --debug, -d    Show all HTTP communications  [boolean] [default: false]
>
> Options:
>   --help  Show help  [boolean]
> ```
>
> [Common Options Reference](https://docs.controlplane.com/cli-reference/using-cli/common-options.md)

***
