# ccp compute



{/* Generated by scripts/sync-cli-reference.ts */}

Deploy and manage long-running compute services

```text
Usage: ccp compute [OPTIONS] <COMMAND>
```

| Argument   | Type or values | Default | Parser environment variable | Description |
| ---------- | -------------- | ------- | --------------------------- | ----------- |
| --help, -h | flag           | —       | —                           | Print help  |

## `ccp compute deploy` [#ccp-compute-deploy]

Deploy or redeploy a compute service

```text
Usage: ccp compute deploy [OPTIONS]
```

| Argument     | Type or values       | Default | Parser environment variable | Description                                                                                                                      |
| ------------ | -------------------- | ------- | --------------------------- | -------------------------------------------------------------------------------------------------------------------------------- |
| --name       | text                 | —       | —                           | Service name (1–64 chars, lowercase alphanumeric + dashes). Required for first deploy                                            |
| --image      | text                 | —       | —                           | Container image to deploy (e.g. nginx:latest). Mutually exclusive with --binary                                                  |
| --binary     | path                 | —       | —                           | Path to a Linux `x86_64` binary. Uploaded directly into a Firecracker VM — no Dockerfile needed. Mutually exclusive with --image |
| --runtime    | auto, alpine, debian | —       | —                           | Binary runtime. auto selects Alpine for musl/static and Debian for glibc                                                         |
| --port       | integer              | —       | —                           | Port the service listens on. Required for first deploy                                                                           |
| --vcpu       | integer              | —       | —                           | Number of virtual CPUs. Must be supplied with --memory-mb                                                                        |
| --memory-mb  | integer              | —       | —                           | Guest memory in MiB. Must be supplied with --vcpu                                                                                |
| --env        | text                 | —       | —                           | Repeatable: --env KEY=VALUE                                                                                                      |
| --org-id     | text                 | —       | —                           | Organization ID (defaults to the Compute link, then context, `CCP_ORG_ID`, saved default, or picker)                             |
| --service-id | text                 | —       | —                           | Update a specific service (skips config lookup)                                                                                  |
| --always-on  | flag                 | false   | —                           | Set `always_on` (first deploy only)                                                                                              |
| --yes, -y    | flag                 | false   | —                           | Skip confirmation prompts                                                                                                        |
| --help, -h   | flag                 | —       | —                           | Print help                                                                                                                       |

## `ccp compute list` [#ccp-compute-list]

List compute services in an organization

```text
Usage: ccp compute list [OPTIONS]
```

Aliases: `ls`.

| Argument   | Type or values | Default | Parser environment variable | Description                                                                                          |
| ---------- | -------------- | ------- | --------------------------- | ---------------------------------------------------------------------------------------------------- |
| --org-id   | text           | —       | —                           | Organization ID (defaults to the Compute link, then context, `CCP_ORG_ID`, saved default, or picker) |
| --json     | flag           | false   | —                           | Emit JSON: full ids, exact timestamps, complete URLs, no styling                                     |
| --help, -h | flag           | —       | —                           | Print help                                                                                           |

## `ccp compute get` [#ccp-compute-get]

Show details for a compute service (deployment history, status)

```text
Usage: ccp compute get [OPTIONS] [SERVICE_ID]
```

| Argument    | Type or values | Default | Parser environment variable | Description                                                                   |
| ----------- | -------------- | ------- | --------------------------- | ----------------------------------------------------------------------------- |
| --json      | flag           | false   | —                           | Emit structured JSON on stdout                                                |
| service\_id | text           | —       | —                           | Service ID or name (defaults to the linked service, or prompts in a terminal) |
| --help, -h  | flag           | —       | —                           | Print help                                                                    |

## `ccp compute logs` [#ccp-compute-logs]

Fetch service logs (last N lines, default 100, max 1000)

```text
Usage: ccp compute logs [OPTIONS] [SERVICE_ID]
```

| Argument    | Type or values | Default | Parser environment variable | Description                                                                   |
| ----------- | -------------- | ------- | --------------------------- | ----------------------------------------------------------------------------- |
| --json      | flag           | false   | —                           | Emit structured JSON on stdout                                                |
| service\_id | text           | —       | —                           | Service ID or name (defaults to the linked service, or prompts in a terminal) |
| --limit, -n | integer        | 100     | —                           | Number of lines to tail                                                       |
| --help, -h  | flag           | —       | —                           | Print help                                                                    |

## `ccp compute exec` [#ccp-compute-exec]

Execute a one-shot command inside the running service

```text
Usage: ccp compute exec [OPTIONS] [SERVICE_ID] -- <CMD>...
```

| Argument     | Type or values | Default | Parser environment variable | Description                                                                   |
| ------------ | -------------- | ------- | --------------------------- | ----------------------------------------------------------------------------- |
| service\_id  | text           | —       | —                           | Service ID or name (defaults to the linked service, or prompts in a terminal) |
| --timeout-ms | integer        | 30000   | —                           | Timeout in milliseconds (default 30000)                                       |
| cmd          | text           | —       | —                           | Command and args (after `--`)                                                 |
| --help, -h   | flag           | —       | —                           | Print help                                                                    |

## `ccp compute restart` [#ccp-compute-restart]

Restart the service (re-runs same image)

```text
Usage: ccp compute restart [OPTIONS] [SERVICE_ID]
```

| Argument    | Type or values | Default | Parser environment variable | Description                                                                   |
| ----------- | -------------- | ------- | --------------------------- | ----------------------------------------------------------------------------- |
| service\_id | text           | —       | —                           | Service ID or name (defaults to the linked service, or prompts in a terminal) |
| --help, -h  | flag           | —       | —                           | Print help                                                                    |

## `ccp compute delete` [#ccp-compute-delete]

Tear down the compute service

```text
Usage: ccp compute delete [OPTIONS] [SERVICE_ID]
```

Aliases: `rm`.

| Argument    | Type or values | Default | Parser environment variable | Description                                                                   |
| ----------- | -------------- | ------- | --------------------------- | ----------------------------------------------------------------------------- |
| service\_id | text           | —       | —                           | Service ID or name (defaults to the linked service, or prompts in a terminal) |
| --yes, -y   | flag           | false   | —                           | Skip confirmation prompt                                                      |
| --help, -h  | flag           | —       | —                           | Print help                                                                    |

## Example [#example]

```bash
ccp compute list --json
```

## Global options [#global-options]

Set `CCP_CONTEXT` to choose a named context. An explicit `--context` takes precedence. See [organization selection](/docs/ccp/organizations) for organization defaults.

| Argument  | Type or values | Default | Parser environment variable | Description                                         |
| --------- | -------------- | ------- | --------------------------- | --------------------------------------------------- |
| --context | text           | —       | —                           | Select a developer context from \~/.ccp/config.toml |
