CosmicAC Logo

Task deployment commands

Reference for the task commands that deploy and operate the CosmicAC stack.

The CosmicAC deployment repository uses Task to deploy and operate the stack. Run a command as task <name> from the deployment directory. task with no argument lists every command.

Commands read variables from .env and the command line. The configuration reference lists the .env variables.

Deploy

CommandWhat it does
task bootstrapDeploys the whole stack from scratch in one command (task bootstrap TAG=release-1.0.0). Runs config-init, start, wire, autobase-connect, register-rack, and migrate-pricing. Generates the service secrets and wires the shared ones, including copying app-node's apiKeySecret to proxy-inference.
task config-initWrites each service's config under services/<repo>/config/ from the image's baked-in defaults. Auto-generates the app-node secrets and the proxy HRPC keypair.
task pullPulls all images at the resolved TAG.
task upCreates and starts the stack. task bootstrap handles a first deployment.

Lifecycle

CommandWhat it does
task startStarts containers stopped by task stop.
task stopStops containers without removing them.
task restartRecreates every container in the stack, even if unchanged.
task downStops and removes the containers and network. Keeps the config and state directories.
task updateUpgrades to a new image tag. Pulls, seeds new config, and recreates changed services. Reads TAG and the optional SERVICES (task update TAG=release-1.0.0).
task recreate-uiRebuilds the UI assets and recreates Caddy.

Status and debugging

CommandWhat it does
taskLists the available commands.
task psShows container status.
task logsFollows logs. SERVICES limits the output (task logs SERVICES="cosmicac-ui").
task configRenders the effective Compose config for debugging.

Authentication

CommandWhat it does
task loginLogs in to GHCR. Uses GITHUB_PAT and GITHUB_USER, or prompts for them.
task ensure-loginLogs in to GHCR only if no credentials are present. Other commands use it as a dependency.

Keys and wiring

CommandWhat it does
task wireDerives runtime keys from the service status files and updates the Compose configs and .env. Links the services' shared keys, including the proxy-inference apiKeySecret.
task ork-keyPrints the ork RPC public key.
task app-node-keyPrints app-node's autobase bootstrap key.
task autobase-connectRegisters every worker's autobase writer key into app-node.
task register-rackRegisters the Kubernetes NVIDIA rack with the ork.
task migrate-pricingApplies K8S_GPU_PRICE to the GPU types on registered racks.
task seed-adminCreates or updates the first-run UI login from the BOOTSTRAP_ADMIN_* variables.

Backup and state

CommandWhat it does
task backupBacks up each service's config and state directories to ./backups/<timestamp>.
task clean-stateDestructive. Empties the status and store directories. SERVICES targets specific services.

On this page