> ## 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.

# General

> Workload reference overview covering access reports, identity assignment, the connect feature for debugging, and replica management across locations.

## Workload Overview

Refer to the [Workload concepts](https://docs.controlplane.com/concepts/workload.md) page.

## Create a Workload

Refer to the [Create a Workload](https://docs.controlplane.com/guides/create-workload.md) guide for additional details.

## Access Report

Displays the permissions granted to principals for the workload. See [Access Report](https://docs.controlplane.com/concepts/access-control.md#access-report) for what each entry shows, how to open it from the Console, CLI, or API, and how groups, query targets, and implied permissions appear in it.

## Event Log

Lists the events recorded for the workload. See the [Event Log reference](https://docs.controlplane.com/reference/events.md) for field details.

## Identity

Refer to the [identities](https://docs.controlplane.com/reference/identity.md) page for additional details.

## Connect

A specific replica of a workload can be connected to (similar to `exec`) from either the console or the CLI. This can be used for troubleshooting any issues with the replica.

To connect using the console, click the `Connect` link from a workload. Select the location, container, replica, and command. Click `Connect` to execute the command. By default, the `bash` shell will be executed.

To connect using the CLI, review the workload [connect](https://docs.controlplane.com/cli-reference/commands/workload.md#workload-connect) subcommand.

## Stop a Replica

Stopping a replica deletes it. For `standard`, `serverless`, and `stateful` workloads, Control Plane starts a replacement to keep the replica count, so stopping one is how you clear a stuck replica without restarting the others. A `stateful` replacement keeps the same replica number and reattaches the same volume. For a `cron` workload, stopping a replica deletes that run's job, and no replacement starts.

Stop a replica with the CLI using [`cpln workload replica stop`](https://docs.controlplane.com/cli-reference/commands/workload#workload-replica-stop). `cpln workload replica get` lists the names of the running replicas.

```shell CLI Example theme={null}
cpln workload replica stop my-workload --replica-name REPLICA_NAME --location aws-us-west-2 --gvc my-gvc --org my-org
```

The CLI submits a `stopReplica` [command](https://docs.controlplane.com/concepts/command.md). You can also submit one yourself with `POST https://api.cpln.io/org/my-org/gvc/my-gvc/workload/my-workload/-command`:

```yaml stopReplica Command theme={null}
type: stopReplica
spec:
  location: aws-us-west-2
  replica: REPLICA_NAME
```

### stopReplica Spec

* `location`
  * **Required**: The name of the location the replica runs in, as specified in your [GVC](https://docs.controlplane.com/reference/gvc.md) configuration.
* `replica`
  * **Required**: The name of the replica to stop.

The command completes once the replica is gone. It fails if no replica with that name exists in the location. It can't be cancelled.

The workload must have a current [deployment](https://docs.controlplane.com/reference/deployment.md) in the location, or the command is rejected with `404` `Workload: NAME does not have any deployments in LOCATION`. A deployment record that hasn't been updated for 24 hours counts as gone; see [stale and expired deployments](https://docs.controlplane.com/reference/deployment.md#stale-and-expired-deployments). A second `stopReplica` for the same replica is rejected with `400` while the first is still in progress. Stopping a replica that a [`runCronWorkload`](https://docs.controlplane.com/reference/workload/types#run-now) command started also cancels that command, unless it has already completed or failed.

Creating a `stopReplica` command requires the `exec.stopReplica` [permission](https://docs.controlplane.com/reference/workload/security.md#permissions).

## Debug

In order to see detailed routing for the global georouted endpoint of a workload, debug values can be included within the response headers of a workload's endpoint request.

The values will only be returned when:

1. `debug` is active and the header `x-cpln-debug: true` is in the request.
2. The global or canonical endpoint is being requested.

Using the console, debug can be activated by:

* Clicking `Options`.
* Clicking the `Debug` switch to `on`.
* Clicking `Save`.

After the workload redeploys, the response from the workload's endpoint will contain the following headers if the header `x-cpln-debug: true` is in the request:

* `x-cpln-location`: Location of the responding replica.
* `x-cpln-replica`: Name of the responding replica.

```text Sample Request Headers theme={null}
GET https://doc-test-v39red0.cpln.app/ HTTP/1.1
Host: doc-test-v39red0.cpln.app
Connection: keep-alive
x-cpln-debug: true
```

```text Sample Response Headers theme={null}
HTTP/1.1 200 OK
content-length: 2993
content-type: text/plain
date: Fri, 10 Sep 2021 21:34:27 GMT
x-envoy-upstream-service-time: 2
x-cpln-location: aws-us-west-2
x-cpln-replica: doc-test-00083-deployment-75584b7d66-f8wtb
```

## Endpoints

### Canonical Endpoint (global)

This URL is globally load-balanced and TLS terminated. This can be used for testing if there is an issue with the custom domain that is associated with the [GVC](https://docs.controlplane.com/reference/gvc.md).

The endpoint can be configured to use the [org endpoint prefix](https://docs.controlplane.com/reference/gvc.md#endpoint-naming-format).
This adds the prefix as a subdomain to `cpln.app`.

#### Canonical Endpoint Formatting

The format depends on whether the GVC is configured to use an org-prefixed name.

* default name: `$workloadName-$gvcAlias.cpln.app`
* org-prefixed name: `$workloadName-$gvcAlias.$orgEndpointPrefix.cpln.app`

#### Disable the Canonical Endpoint

To stop serving a workload on its public canonical endpoint, add the tag `cpln/skipGVCDomain` with the value `true`. Use it when the workload must only be reachable through a [custom domain](https://docs.controlplane.com/reference/domain.md), its location-specific endpoints, or internally.

```bash Add the tag theme={null}
cpln workload tag WORKLOAD --gvc GVC --tag cpln/skipGVCDomain=true
```

```bash Remove the tag theme={null}
cpln workload tag WORKLOAD --gvc GVC --remove-tag cpln/skipGVCDomain
```

```yaml Workload manifest theme={null}
kind: workload
name: WORKLOAD
tags:
  cpln/skipGVCDomain: 'true'
```

With the tag set on a standard, stateful, or serverless workload:

* Requests to the canonical endpoint (`$workloadName-$gvcAlias.cpln.app` or its org-prefixed form) are rejected, typically with `421 Misdirected Request`.
* The canonical hostname still resolves in DNS, and the workload status still lists it. Control Plane uses the record for routing between locations.
* These endpoints keep working:
  * [location-specific endpoints](#location-specific-endpoint)
  * [replica-direct endpoints](#replica-direct-endpoints)
  * [custom domain](https://docs.controlplane.com/reference/domain.md) routes, including a domain scoped to the GVC
  * the [internal endpoint](#internal-mutual-tls-endpoint) (`$workloadName.$gvcName.cpln.local`)

Removing the tag serves the canonical endpoint again. Adding or removing the tag rolls out the workload's replicas, like any other spec change.

### Location-Specific Endpoint

One endpoint will be created for each location in the [GVC](https://docs.controlplane.com/reference/gvc.md).

Format: `$workloadName-$gvcAlias.$locationName.controlplane.us`

### Replica-Direct Endpoints

For stateful workloads, Control Plane optionally provides endpoints which point directly to each workload replica.

Format: `$workloadName-$gvcAlias-$replicaIndex.$locationName.controlplane.us`
Example: stateful-workload-name-cry3tqvce07s4-0.aws-us-west-2.controlplane.us

> [!NOTE]
>
> These are built-in `controlplane.us` endpoints. For per-replica access under your own custom domain, see [Replica Direct Routing](https://docs.controlplane.com/reference/domain.md#replica-direct-routing) in the Domain reference.

### Custom Domain Endpoints

Additional globally load-balanced endpoints will show in the workload status for each domain route that is configured to use this workload.

### Internal Mutual-TLS Endpoint

Each workload can be allowed to receive requests from other workloads in the same org internally using the provided internal endpoint. Access to this endpoint is controlled by the internal firewall settings.

#### Internal Endpoint Formatting

Typically, the workload endpoint is used. For stateful workloads with `replicaDirect` enabled, you may also use the replica-direct endpoint

* workload: `$workloadName.$gvcName.cpln.local:$port`
* replica-direct:  `replica-$replicaIndex.$workloadName.$locationName.$gvcName.cpln.local:$port`

#### Internal Routing and Location Failover

`spec.networking.internal.routing` controls where requests to `$workloadName.$gvcName.cpln.local` go when they come from a workload in the **same** [GVC](https://docs.controlplane.com/reference/gvc.md). Set it on the workload being called.

| Value | Behavior |
| :- | :- |
| `locationEndpoint` | Requests are served only by replicas in the caller's location. If no local replica can serve them, the request fails. This is also the behavior when the field is not set. |
| `gvcEndpoint` | Requests are served by local replicas while they are healthy. As local replicas become unavailable, requests fail over to the workload's [canonical endpoint](#canonical-endpoint-global), which routes to another location that passes its health check. |

```yaml Workload manifest theme={null}
kind: workload
name: WORKLOAD
spec:
  networking:
    internal:
      routing: gvcEndpoint
```

**Defaults:**

* New workloads default to `gvcEndpoint`.
* Workloads created before this field was introduced have no value, which behaves as `locationEndpoint`. They are not changed automatically. Set `gvcEndpoint` to opt in.
* To see a workload's current setting, run `cpln workload get WORKLOAD --gvc GVC -o json` and check `spec.networking.internal.routing`.
* An explicit value is always kept. Re-applying a manifest that omits the field with `cpln apply` keeps the stored value.

**When failover happens:** local replicas are preferred.

* **Full failover:** all requests go to another location when the workload has no ready replicas in the caller's location, for example when it is suspended there with [`spec.localOptions`](#location-specific-options).
* **Partial failover:** when only some local replicas are unhealthy (not ready, or temporarily removed from load balancing after returning errors), a share of requests can go to another location while the rest stay local.
* **Recovery:** traffic returns to local replicas once they are healthy again. A replica removed after returning errors is retried after about 30 seconds.

Failover traffic stays on the service mesh and uses mutual TLS, just like calls between GVCs. The target's [internal firewall](https://docs.controlplane.com/reference/workload/firewall.md#internal) still applies in the remote location, so a caller that is not allowed is rejected there with `403 Forbidden`.

**Requirements and limits:**

* The setting only takes effect when the GVC has more than one location and the workload is deployed in at least one other location.
* Callers in a **different** GVC already reach the workload through its canonical endpoint, so this setting does not change their routing.
* Outbound ports that the caller excludes from the service mesh with `cpln/disableServiceMeshOutboundPort` bypass mesh routing, so requests on those ports never fail over.
* Requests can fail for a brief period before failover completes, while the failure is being detected.
* For workloads that only expose TCP ports, location health is checked at the TCP level. A location that has no ready replicas but is not suspended can still be selected.

> [!WARNING]
>
> Requests that fail over leave the caller's location and are billed as egress. New workloads default to `gvcEndpoint`, so set `locationEndpoint` if a workload's internal traffic must stay in one location.

### Finding Replica Hostnames

When `replicaDirect` is enabled on a stateful workload, each replica is reachable at its own stable hostname, letting you target a specific replica instead of load-balancing across all of them:

* Internal (workload-to-workload): use the [replica-direct internal endpoint](#internal-endpoint-formatting), `replica-$replicaIndex.$workloadName.$locationName.$gvcName.cpln.local:$port`.
* External: use the [replica-direct endpoint](#replica-direct-endpoints), `$workloadName-$gvcAlias-$replicaIndex.$locationName.controlplane.us`.

Replica indexes start at `0` and run to one less than the replica count, so you can enumerate every replica's hostname from the workload name, location, GVC, and index. These names are served by Control Plane's internal DNS, so you construct them directly — there's no need to connect into the container to discover them.

## Publish Not-Ready Addresses

By default, Control Plane only routes internal traffic to workload replicas that have passed their readiness probe. For clustered applications that need to discover peers during startup (before becoming ready), you can enable publishing not-ready addresses.

To enable this feature, add the following tag to your workload:

| Tag | Value |
| :- | :- |
| `cpln/publishNotReadyAddresses` | `true` |

When enabled, the internal service endpoint will include all pod IP addresses, even those that haven't passed their readiness probe yet. This is useful for:

* Distributed databases that need peer discovery during initialization
* Clustered applications where nodes must communicate before becoming ready
* Any application using StatefulSet-style stable network identities for bootstrapping

> [!WARNING]
>
> Enabling this feature means traffic may be routed to pods that are not yet ready to handle requests. Only use this for applications specifically designed to handle connections during startup.

## Inter-Container Communication

Containers deployed within the same workload can communicate with each other using their names and assigned ports. This setup facilitates direct networking between containers.

* **Container Identification** - Each container is uniquely identified by its name.
* **Port Allocation** - Containers are assigned specific ports for network communication.

### Example Scenario

* Imagine two containers within the same workload: `foo` and `bar`.
* Container `foo` is running on port **4020**.
* Container `bar` is running on port **4030**.

`foo` can access `bar` using the URL **[http://bar:4030](http://bar:4030)**. This URL combines the name of the destination container `bar` and its assigned port **4030**, enabling direct communication between the two containers.

This method ensures efficient and organized networking within a multi-container workload environment.

## Built-in Variables

Each workload has the following built-in environment variables:

| Variable Name | Description | Format |
| :- | :- | :- |
| CPLN\_GLOBAL\_ENDPOINT | The canonical Host header that the container will receive requests on | `${\workloadName}-${gvcAlias}.cpln.app` |
| CPLN\_GVC | The Global Virtual Cloud (/reference/gvc) the container is running under | string |
| CPLN\_GVC\_ALIAS | The Global Virtual Cloud Alias | 13 digit alphanumeric value |
| CPLN\_LOCATION | The [location](https://docs.controlplane.com/reference/location.md) the container is serving the request from | aws-us-west-2, azure-eastus2, gcp-us-east1, etc. |
| CPLN\_NAMESPACE | The namespace of the container | Generated random string (e.g., aenhg2ec6pywt) |
| CPLN\_PROVIDER | The cloud provider the container is serving the request from | aws, azure, gcp, etc. |
| CPLN\_ORG | The org the container is running under | string |
| CPLN\_WORKLOAD | The workload the container is running under | string |
| CPLN\_WORKLOAD\_VERSION | The Control Plane version of the Workload, only updated when needed to apply changes. For example, changing scaling settings will not cause this to change. | numeric |
| CPLN\_TOKEN | A token used to authenticate to the Control Plane CLI / API | Random authorization token |
| CPLN\_IMAGE | The image as defined for this container in the Control Plane api | string |

> [!NOTE]
>
> Since a workload identity can be the target of a policy, a running workload can be authorized to exercise the
> Control Plane [CLI](https://docs.controlplane.com/cli-reference/overview.md) or [API](https://docs.controlplane.com/api-reference/api.md) without any additional authentication.
>
> Examples:
>
> * Direct call to the Control Plane API:
>
>   * `curl ${CPLN_ENDPOINT}/org/${CPLN_ORG} -H "Authorization: ${CPLN_TOKEN}"`
> * If the Control Plane CLI installed:
>   * `cpln org get ${CPLN_ORG}`
>
> \*\* The value of CPLN\_TOKEN is valid only if the request originates from the workload it is injected in. If it is used from another workload or externally, a `403 Forbidden` response will be returned. \*\*

> [!TIP]
>
> If a workload is not assigned an identity, it can still `GET` its parent org.

## Logs

Workload logs are consolidated from all the deployed locations and can be viewed using the UI or CLI.

Using the UI, the logs page will be prefilled with the [LogQL](https://grafana.com/docs/loki/latest/logql/)
query for the workload and [GVC](https://docs.controlplane.com/reference/gvc.md) name.

```log Example LogQL Query theme={null}
  {gvc="test-gvc", workload="test-workload"}
```

Logs can be further filtered by:

* `Date`
* `Location`
* `Container`

Grafana can be used to view the logs by clicking the `Explore on Grafana` link within the console.

Refer to the [logs](https://docs.controlplane.com/core/logs.md) page for additional details.

## Rollout Options

Settings to control the rollout process between versions.

```yaml YAML theme={null}
spec:
  rolloutOptions:
    minReadySeconds: 0
    maxUnavailableReplicas: 1
    maxSurgeReplicas: 100%
    scalingPolicy: OrderedReady
    terminationGracePeriodSeconds: 30
```

### minReadySeconds

The minimum number of seconds that a workload replica must be running before the rollout progresses.

### maxUnavailableReplicas

The maximum number or percentage of replicas that can be unavailable during a rollout or during regular rescheduling of workloads.

### maxSurgeReplicas

The maximum number or percentage of new replicas that can be added during a rollout for each batch. Applies only to `standard` workloads; other workload types ignore it.

Example: If there are 4 running replicas and maxSurgeReplicas is set to 50%, then during each rollout 2 replicas will be added at the new version. Once they are healthy as determined by the [ReadinessProbe](#readiness-probe), the rollout will continue, -2 old replicas, +2 new replicas, -2 old replicas.

In cases where a short rollout cutover is needed, a maxSurgeReplicas setting of `100%` is recommended.

### scalingPolicy

The strategies used to update applications and services deployed. Valid values: `OrderedReady` (Updates workloads in a rolling fashion, taking down old ones and bringing up new ones incrementally, ensuring that the service remains available during the update.), `Parallel` (Causes all pods affected by a scaling operation to be created or destroyed simultaneously. This does not affect update operations.). Default: `OrderedReady`.

## Automatic Retries

Settings to control automatic http/grpc request retries

```yaml YAML theme={null}
spec:
  requestRetryPolicy:
    attempts: 2
    retryOn:
      - connect-failure
      - '501'
```

### attempts

The amount of retries before sending the response to the client.
By default, attempts will be set to `2`.

### retryOn

Indicates under which circumstances a retry should be attempted. Can include [HTTP](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-on) or [GRPC](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_filters/router_filter#x-envoy-retry-grpc-on) policies.

By default, retryOn will be set to `[connect-failure,refused-stream,unavailable,cancelled,resource-exhausted,retriable-status-codes]`

## Default Ephemeral Storage

Each workload replica receives at least 1GB of local ephemeral solid state drive (SSD) storage. Workloads that request more than 1 core of CPU receive 1GB of storage for each core. For example, a workload that requests 1500 millicore of CPU can consume up to 1.5GB of ephemeral storage.

If the replica uses more than its allotted ephemeral storage, it will be replaced with a new replica.

## Suspend

Each workload can be suspended which immediately stops the workload from serving traffic. This is the same as setting the min/max scale to 0. When the workload is unsuspended, it will resume serving traffic.

To temporarily deactivate a workload choose `Stop` from the Actions menu.

```yaml YAML theme={null}
spec:
  defaultOptions:
    suspend: true
```

The workload will stop running and will not serve any traffic.

To reactivate the workload, choose `Start` from the actions menu.

```yaml YAML theme={null}
spec:
  defaultOptions:
    suspend: false
```

## Timeout Seconds

`spec.defaultOptions.timeoutSeconds`

The maximum request duration in seconds before Control Plane will timeout. This timeout amount can be reached when Control Plane is waiting for the workload to respond or when waiting for a new workload to become available when using Autoscaling.

The default is **5 seconds** and the minimum is **1 second**. The maximum depends on the workload type:

| Workload type | Maximum |
| :- | :- |
| Serverless | 600 seconds (10 minutes) |
| Standard | 3600 seconds (1 hour) |
| Stateful | 3600 seconds (1 hour) |
| VM | 3600 seconds (1 hour) |
| Cron | Not applicable |

> [!WARNING]
>
> The timeout is an upper limit, not a guarantee that a request can run for that long. In some cases a node needs to be taken offline quickly, and a request in progress on that node can be interrupted before its timeout is reached. Design long-running requests so that they can be retried safely. See [Termination](https://docs.controlplane.com/reference/workload/termination.md) for how replicas shut down.

### Metering and Billing

The CPU, memory and egress used for mounted object stores are billed to the workload. To review the costs of mounting an object store, query the container named `cpln-mounter` for the workload within the metrics page.

## Location-Specific Options

`spec.localOptions`

[`spec.defaultOptions`](#suspend) applies to the workload in every [location](https://docs.controlplane.com/reference/location.md) its [GVC](https://docs.controlplane.com/reference/gvc.md) spans. `spec.localOptions` sets different options in named locations, and it is the only mechanism that does so.

It is an array. Each entry carries the same fields as `defaultOptions` plus a `location` link, which is required:

```yaml YAML theme={null}
spec:
  defaultOptions:
    autoscaling:
      minScale: 1
      maxScale: 3
  localOptions:
    - location: //location/aws-eu-central-1
      autoscaling:
        minScale: 3
        maxScale: 10
    - location: //location/aws-us-west-2
      suspend: true
```

The workload above runs 1 to 3 replicas everywhere its GVC reaches, 3 to 10 in `aws-eu-central-1`, and is switched off in `aws-us-west-2`.

Setting `suspend` in a `localOptions` entry stops the workload in that location without removing the location from the GVC. A workload with some locations suspended and others running reports `partiallySuspended`; see [Suspend](#suspend).

## Workload Health

* Possible values:
  * `Loading`
  * `Healthy`
  * `Unhealthy`
  * `Deleting`
  * `Unknown`

## Multi-Zone

Multi-zone deployment distributes workload replicas across multiple availability zones within a location for higher availability. When enabled, Control Plane will attempt to spread replicas evenly across available zones.

```yaml YAML theme={null}
spec:
  defaultOptions:
    multiZone:
      enabled: true
```

### Configuration

| Property | Type | Description |
| :- | :- | :- |
| `enabled` | boolean | Enable multi-zone replica distribution. Default: `false` |

> [!NOTE]
>
> Not all locations support multi-zone deployments. Confirm that your target location supports multiple availability zones before enabling this option.

> [!TIP]
>
> When using multi-zone with a dedicated load balancer, enable `multiZone` on the GVC's load balancer settings as well to reduce cross-zone traffic costs.

## Special Tags

Control Plane supports special tags prefixed with `cpln/` that modify workload behavior. These tags provide access to advanced or niche configuration options that have not yet been implemented as first-class API options.

> [!NOTE]
>
> Some tags listed below are deprecated in favor of first-class spec options. Where indicated, prefer using the spec option as tags may be removed in future releases.

### Traffic and Networking

| Tag | Value | Description | Status |
| :- | :- | :- | :- |
| `cpln/publishNotReadyAddresses` | `true` | Routes internal traffic to replicas that haven't passed their readiness probe. See [Publish Not-Ready Addresses](#publish-not-ready-addresses). | |
| `cpln/protocol` | `http`, `http2`, `grpc`, `tcp` | Override the protocol detection for the workload. | Deprecated. Use [`ports[].protocol`](https://docs.controlplane.com/reference/workload/containers#protocol). |
| `cpln/bypassProxyOutbound` | `true` | Bypass the service mesh proxy for outbound traffic. | |
| `cpln/disableServiceMeshInboundPort` | comma-separated port numbers, no spaces (for example `9000,9001`) | Exclude one or more inbound ports from the service mesh. | |
| `cpln/disableServiceMeshOutboundPort` | comma-separated port numbers, no spaces (for example `5432,3306`) | Exclude one or more outbound ports from the service mesh. | |
| `cpln/multiZone` | `true` | Enable multi-zone deployment for the workload. | Deprecated. Use [`spec.defaultOptions.multiZone`](#multi-zone). |
| `cpln/skipLocationEndpointHeaders` | `true` | Skip adding location endpoint headers in redirect responses. | |
| `cpln/skipGVCDomain` | `true` | Stop serving the workload on its public canonical endpoint. Location endpoints, custom domains, and `cpln.local` keep working. See [Disable the Canonical Endpoint](#disable-the-canonical-endpoint). | |
| `cpln/discoverCrossGvcReplicas` | `true` | Enable discovery of replicas across different GVCs via mTLS. | |

### Observability

| Tag | Value | Description |
| :- | :- | :- |
| `cpln/tracingDisabled` | `true` | Disable distributed tracing for this workload. |

### BYOK and Direct Load Balancer Tags

These tags are only available for workloads running on [BYOK](https://docs.controlplane.com/reference/location.md#byok-locations) clusters or workloads with [Direct Load Balancer](https://docs.controlplane.com/reference/workload/load-balancing.md#direct-load-balancer) enabled.

| Tag | Value | Description |
| :- | :- | :- |
| `cpln/disableServiceMesh` | `true` | Disable the service mesh entirely. |
| `cpln/disableServiceMeshOutboundCIDR` | comma-separated CIDR ranges, no spaces (for example `10.0.0.0/8,192.168.0.0/16`) | Exclude one or more CIDR ranges from service mesh outbound traffic. |
| `cpln/k8sClusterRole` | role name | Bind a Kubernetes ClusterRole to the workload's service account. BYOK only. |

### External Authorization

Configure an external authorization service for the workload. All requests will be checked against this service before being processed.

| Tag | Value | Default | Description |
| :- | :- | :- | :- |
| `cpln/externalAuthAddress` | hostname/IP | (required) | Address of the external auth service. |
| `cpln/externalAuthPort` | port | `443` | Port of the external auth service. |
| `cpln/externalAuthProtocol` | `grpc`, `http` | `grpc` | Protocol to use for auth requests. |
| `cpln/externalAuthScheme` | `https`, `http` | `https` | URL scheme for the auth service. |
| `cpln/externalAuthTimeout` | duration | `1s` | Timeout for auth requests. |
| `cpln/externalAuthFailureAllow` | `true`, `false` | `true` | Allow requests if auth service fails. |
| `cpln/externalAuthPackAsBytes` | `true`, `false` | `false` | Pack request body as bytes. |
| `cpln/externalAuthRemoveRequestBody` | `true`, `false` | `false` | Remove request body before forwarding. |
| `cpln/externalAuthIncludePeerCert` | `true`, `false` | `false` | Include client certificate in auth request. |
| `cpln/externalAuthPathPrefix` | path | - | Path prefix for auth requests. |
| `cpln/externalAuthUpstreamHeaderPrefixes` | prefixes | - | Header prefixes to forward upstream. |
| `cpln/externalAuthListenPort` | port | - | Specific listen port to apply auth to. |

### External Rate Limiting

Configure an external rate limiting service for the workload.

| Tag | Value | Default | Description |
| :- | :- | :- | :- |
| `cpln/rateLimitAddress` | hostname/IP | (required) | Address of the rate limit service. |
| `cpln/rateLimitPort` | port | `443` | Port of the rate limit service. |
| `cpln/rateLimitDomain` | string | `cpln` | Rate limit domain identifier. |
| `cpln/rateLimitScheme` | `https`, `http` | `https` | URL scheme for the rate limit service. |
| `cpln/rateLimitDescriptors` | string | `authority` | Descriptors to use for rate limiting. |

## CLI

To view the CLI documentation for Workloads, see the [Workload CLI reference](https://docs.controlplane.com/cli-reference/commands/workload.md).
