# arena cluster

Manage Arena enterprise clusters.

### Usage

```shell
arena cluster [OPTIONS] COMMAND [ARGS]...
```

## arena cluster connect

Connect a Kubernetes cluster to Arena in one step.

Runs preflight and stops on a failed check, then registers the cluster
(an existing name keeps its token), installs the agent, and waits until
it connects and reports its health after the install finishes. Lists
the resource classes Arena suggests from the cluster’s nodes and
creates them on --yes or after a prompt.

### Usage

```shell
arena cluster connect [OPTIONS]
```

### Options

### --name <name>

**Required** Arena cluster name.

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --agent-namespace <agent_namespace>

Kubernetes namespace for the agent Helm release.

* **Default:**
  `'arena'`

### --storage-endpoint <storage_endpoint>

Object storage endpoint.

### --storage-bucket <storage_bucket>

Object storage bucket.

### --storage-prefix <storage_prefix>

Object storage prefix.

### --storage-secret-name <storage_secret_name>

Secret in the agent namespace that holds the storage credentials.

### --ray-data-storage-class-name <ray_data_storage_class_name>

StorageClass for Ray data. Defaults to the cluster’s default StorageClass.

### --rotate-token

Issue a new agent token for a cluster that is already registered. The previous token keeps working for 24 hours.

### --wait-timeout <wait_timeout>

Seconds to wait for the agent to connect and send its health report.

* **Default:**
  `900.0`

### --yes

Create the resource classes Arena suggests without prompting.

## arena cluster destroy

Destroy the cloud cluster recorded in the selected Terraform state.

### Usage

```shell
arena cluster destroy [OPTIONS]
```

### Options

### --spec <spec>

Cloud cluster provisioning YAML file.

### --name <name>

Cluster name in Arena. Used when --spec is omitted.

### --state-dir <state_dir>

Terraform state directory (default: ./arena-cluster-NAME/terraform).

### --delete-storage

Force-delete experiment object storage (data, metrics, and checkpoints). Kept otherwise.

### --delete-storage-project

Delete experiment object storage, the Terraform state bucket, and the Nebius storage project that provisioning created.

### --all

Delete this cluster’s buckets and IAM, including its Nebius region projects. The Terraform state bucket is deleted last.

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

### --yes

Destroy without prompting.

## arena cluster generate-spec

Write a default cluster spec YAML with placeholder cloud IDs.

### Usage

```shell
arena cluster generate-spec [OPTIONS]
```

### Options

### --provider <provider>

Cloud provider for the generated spec.

* **Default:**
  `'nebius'`
* **Options:**
  nebius | aws

### --name <name>

Cluster name written into the spec (default: arena-PROVIDER).

### --output <output>

Destination YAML path (default: ./NAME.yaml).

### --force

Overwrite an existing file.

## arena cluster manifest

Write the GitOps manifest for the agent at this Arena release.

The manifest pins the agent chart and holds no secrets. On a new
cluster, run the install package’s bootstrap command first. To upgrade,
commit the new manifest.

### Usage

```shell
arena cluster manifest [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --format <manifest_format>

**Required** argocd: an Argo CD Application. flux: a Flux HelmRepository and HelmRelease.

* **Options:**
  argocd | flux

### -o, --output <output>

File to write. Standard output when omitted.

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.

## arena cluster plan

Create a cloud cluster plan without applying it.

### Usage

```shell
arena cluster plan [OPTIONS]
```

### Options

### --spec <spec>

**Required** Cloud cluster provisioning YAML file.

### --state-dir <state_dir>

Terraform state directory (default: OUTPUT_DIR/terraform).

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

### --byoc-scope <byoc_scope>

customer keeps this org’s bucket. platform shares the Arena catalog and bucket and requires a platform admin. Choosing platform uses ephemeral placement unless --placement is set.

* **Options:**
  customer | platform

### --placement <placement>

Override values.placement. in-cluster runs jobs in this cluster; ephemeral hunts capacity outside it.

* **Options:**
  in-cluster | ephemeral

### --ray-data-pvc-size <ray_data_pvc_size>

Override the Ray data PVC size.

### --ray-data-storage-class-name <ray_data_storage_class_name>

Override the Ray data storage class.

### --preprocessing-resource-class <preprocessing_resource_class>

Override the preprocessing resource class name.

### --tls-secret-name <tls_secret_name>

Override the inference TLS secret.

### --gateway-api-parent-refs <gateway_api_parent_refs>

Override Gateway API parent refs JSON.

### --hostname-template <hostname_template>

Override the inference hostname template.

### --domain <domain>

Override the inference DNS domain.

### --ingress-class-name <ingress_class_name>

Override the inference ingress class.

### --storage-secret-name <storage_secret_name>

Override the object storage secret name.

### --storage-prefix <storage_prefix>

Override the object storage prefix.

### --storage-bucket <storage_bucket>

Override the object storage bucket.

### --storage-endpoint <storage_endpoint>

Override the object storage endpoint.

### --name <name>

Override the cluster name from --spec.

### --create-state-bucket

Create the Terraform state bucket if it is missing.

## arena cluster preflight

Check that a Kubernetes cluster can run the Arena agent.

Read-only: changes nothing in Arena or the cluster. Exits non-zero when
a check fails.

### Usage

```shell
arena cluster preflight [OPTIONS]
```

### Options

### --name <name>

Arena cluster name. When Arena already has this cluster, its own agent does not count as a second one.

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --agent-namespace <agent_namespace>

Kubernetes namespace for the agent Helm release.

* **Default:**
  `'arena'`

### --ray-data-storage-class-name <ray_data_storage_class_name>

StorageClass for Ray data. Defaults to the cluster’s default StorageClass.

### --json

Print the report as one JSON document, for the Arena web wizard.

## arena cluster provision

Provision a cloud Kubernetes cluster from a YAML spec.

### Usage

```shell
arena cluster provision [OPTIONS] [nebius|aws]
```

### Options

### --spec <spec>

**Required** Cloud cluster provisioning YAML file.

### --state-dir <state_dir>

Terraform state directory (default: OUTPUT_DIR/terraform).

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

### --byoc-scope <byoc_scope>

customer keeps this org’s bucket. platform shares the Arena catalog and bucket and requires a platform admin. Choosing platform uses ephemeral placement unless --placement is set.

* **Options:**
  customer | platform

### --placement <placement>

Override values.placement. in-cluster runs jobs in this cluster; ephemeral hunts capacity outside it.

* **Options:**
  in-cluster | ephemeral

### --ray-data-pvc-size <ray_data_pvc_size>

Override the Ray data PVC size.

### --ray-data-storage-class-name <ray_data_storage_class_name>

Override the Ray data storage class.

### --preprocessing-resource-class <preprocessing_resource_class>

Override the preprocessing resource class name.

### --tls-secret-name <tls_secret_name>

Override the inference TLS secret.

### --gateway-api-parent-refs <gateway_api_parent_refs>

Override Gateway API parent refs JSON.

### --hostname-template <hostname_template>

Override the inference hostname template.

### --domain <domain>

Override the inference DNS domain.

### --ingress-class-name <ingress_class_name>

Override the inference ingress class.

### --storage-secret-name <storage_secret_name>

Override the object storage secret name.

### --storage-prefix <storage_prefix>

Override the object storage prefix.

### --storage-bucket <storage_bucket>

Override the object storage bucket.

### --storage-endpoint <storage_endpoint>

Override the object storage endpoint.

### --name <name>

Override the cluster name from --spec.

### --output-dir <output_dir>

Directory for kubeconfig and generated Helm values.

### --register-and-install

Register the cluster with Arena and install the Helm agent.

### --agent-namespace <agent_namespace>

Kubernetes namespace for the agent Helm release when installing.

* **Default:**
  `'arena'`

### --yes

Apply without prompting.

### --create-state-bucket

Create the Terraform state bucket if it is missing.

### Arguments

### PROVIDER

Optional argument

## arena cluster register

Register a Kubernetes cluster and write Helm install bundles.

Re-running with the same `--name` updates the existing cluster (upsert)
and keeps its agent token; `--rotate-token` issues a new one.
Object storage is optional. `--install` deploys the agent chart.
`--install-storage` requests bundled MinIO and installs that chart.
`--lab` is `--install-storage --narrow-allowed-ips`.
`--byoc-scope platform` shares the Arena catalog and bucket.

### Usage

```shell
arena cluster register [OPTIONS] [nebius|aws]
```

### Options

### -v, --verbose

Show detailed command traces.

### --yes

Provision and create suggested classes without prompting.

### --create-state-bucket

Create the Terraform state bucket when provisioning a missing cluster. terraform_state.create_bucket in the spec does the same.

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

### --state-dir <state_dir>

Terraform state directory (default: ./arena-cluster-NAME/terraform).

### --agent-namespace <agent_namespace>

Kubernetes namespace for the agent Helm release.

* **Default:**
  `'arena'`

### --no-helm-wait

Do not wait for Helm storage resources or the agent Deployment.

### --charts-dir <charts_dir>

Platform development only: path to agilerl-platform/resources/helm-setup instead of downloading charts from Arena.

### --rotate-token

Issue a new agent token for a cluster that is already registered. The previous token keeps working for 24 hours.

### --no-write

Do not persist Helm values or token files under --output-dir.

### --lab

Lab k3d profile: same as --install-storage --narrow-allowed-ips.

### --narrow-allowed-ips

Omit 10.0.0.0/8 from WireGuard AllowedIPs (k3d/k3s ClusterIP).

### --install-storage

Mint bundled MinIO values and install the storage chart.

### --install

Run helm upgrade --install for the agent chart.

### --force

Overwrite existing output files.

### --skip-enable

Skip enabling the BYOC provider (use when it is already enabled).

### --output-dir <output_dir>

Directory for Helm values and token (default: ./arena-cluster-NAME).

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --byoc-scope <byoc_scope>

customer keeps this org’s bucket. platform shares the Arena catalog and bucket and requires a platform admin. Choosing platform uses ephemeral placement unless --placement is set.

* **Options:**
  customer | platform

### --placement <placement>

Override values.placement. in-cluster runs jobs in this cluster; ephemeral hunts capacity outside it.

* **Options:**
  in-cluster | ephemeral

### --ray-data-pvc-size <ray_data_pvc_size>

Override the Ray data PVC size.

### --ray-data-storage-class-name <ray_data_storage_class_name>

Override the Ray data storage class.

### --preprocessing-resource-class <preprocessing_resource_class>

Override the preprocessing resource class name.

### --tls-secret-name <tls_secret_name>

Override the inference TLS secret.

### --gateway-api-parent-refs <gateway_api_parent_refs>

Override Gateway API parent refs JSON.

### --hostname-template <hostname_template>

Override the inference hostname template.

### --domain <domain>

Override the inference DNS domain.

### --ingress-class-name <ingress_class_name>

Override the inference ingress class.

### --storage-secret-name <storage_secret_name>

Override the object storage secret name.

### --storage-prefix <storage_prefix>

Override the object storage prefix.

### --storage-bucket <storage_bucket>

Override the object storage bucket.

### --storage-endpoint <storage_endpoint>

Override the object storage endpoint.

### --name <name>

Override the cluster name from --spec.

### --spec <spec>

Cloud cluster YAML file that supplies registration settings.

### Arguments

### PROVIDER

Optional argument

## arena cluster register-classes

Register Nebius GPU presets as Arena resource classes on an existing cluster.

### Usage

```shell
arena cluster register-classes [OPTIONS]
```

### Options

### --spec <spec>

**Required** Cloud cluster provisioning YAML file.

### --state-dir <state_dir>

Terraform state directory (default: OUTPUT_DIR/terraform).

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

### --output-dir <output_dir>

Directory for the kubeconfig written when new node groups are applied.

### --all

Register every GPU preset in the Nebius project.

### --preset <requested_presets>

Register one preset, as platform:preset. Repeat to register several.

### --yes

Apply without prompting.

### --register-node-group

Create the Nebius node group for each selected preset, then register the class.

## arena cluster revoke-token

Revoke every credential of the cluster now, for a leaked one. The agent is refused until you run arena cluster connect again.

### Usage

```shell
arena cluster revoke-token [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --yes

Do not ask first.

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.

## arena cluster rotate-token

Ask the cluster’s agent to renew its credential. The current one keeps working until the agent uses the new one.

### Usage

```shell
arena cluster rotate-token [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --yes

Do not ask first.

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.

## arena cluster smoke

Check that a BYOC cluster can run jobs.

The cluster’s agent installs a small train release as its own
ServiceAccount, the way it installs a job, waits until its Ray head is
Ready, and removes it. The release mounts no storage and asks for no
GPU. The command fails with the agent’s reason when the release does
not come up.

### Usage

```shell
arena cluster smoke [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --timeout <timeout>

Seconds to wait for the result.

* **Default:**
  `3600.0`

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.

## arena cluster status

Show Terraform outputs for a provisioned cluster.

### Usage

```shell
arena cluster status [OPTIONS]
```

### Options

### --spec <spec>

**Required** Cloud cluster provisioning YAML file.

### --state-dir <state_dir>

Terraform state directory (default: OUTPUT_DIR/terraform).

### --module-version <module_version>

Terraform module release to install. Upgrades a cluster that already has a pin.

## arena cluster unregister

Remove a BYOC cluster from Arena by name.

Arena refuses a cluster with runs unless --stop-runs stops them. Its
agent then deletes the job namespaces it created and Arena archives the
cluster and its classes and revokes its tokens. The agent Helm release
is uninstalled after that, unless declined.

### Usage

```shell
arena cluster unregister [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --stop-runs

Stop the cluster’s experiments and deployments first.

### --force

Archive the cluster now without waiting for its agent, for an agent that is offline. Arena ends its runs. Uninstalling the agent release removes its job namespaces; if the release stays, run the printed command.

### --uninstall-helm

Uninstall the agent Helm release without prompting. Does not uninstall MinIO.

### --keep-agent

Leave the agent Helm release installed.

### --uninstall-storage

Uninstall the MinIO storage Helm release without prompting. Deletes checkpoints, metrics, and datasets.

### --wait-timeout <wait_timeout>

Seconds to wait for the agent to clean up.

* **Default:**
  `600.0`

### --yes

Unregister without prompting. Uninstalls nothing without --uninstall-helm.

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.

## arena cluster upgrade

Upgrade the BYOC agent chart without changing cluster credentials.

### Usage

```shell
arena cluster upgrade [OPTIONS]
```

### Options

### --name <name>

**Required** Registered cluster name.

### --kubeconfig <kubeconfig>

Kubeconfig for the agent cluster. Defaults to arena-cluster-NAME/kubeconfig when that file exists.

### --context <kube_context>

Kubernetes context to use. Without it or --kubeconfig, the command shows the current context and asks first.

### --agent-namespace <agent_namespace>

Kubernetes namespace for the agent Helm release. Defaults to the namespace Helm reports for this cluster.

### --no-helm-wait

Do not wait for the agent Deployment.

### --yes

Apply agent ClusterRole changes without prompting.

### --platform

Target AgileRL’s own platform clusters, which needs AgileRL staff access.
