kapapra.toml

Tune the build and start from your repository.

The file

Optional file at the root of the repository (or of the root directory). Its values win over the console’s for the current deployment, without changing them. An unknown section or field fails the build with an explicit message.

[service]
port = 8080
replicas = 2

[build]
command = "pnpm install && pnpm build"
dockerfile_path = "apps/api/Dockerfile"
args = ["SENTRY_RELEASE"]
secrets = ["NPM_TOKEN"]

[deploy]
start_command = "pnpm start"
healthcheck_path = "/healthz"

Variables at build time

Variables prefixed with VITE_, NEXT_PUBLIC_ or PUBLIC_ are always passed to the build (they end up in front-end code). Others are passed only when listed:

  • build.args: passed as --build-arg, visible in the image history: never put a secret here;
  • build.secrets: passed as BuildKit secrets, never written to the image. Requires a Dockerfile: RUN --mount=type=secret,id=NPM_TOKEN NPM_TOKEN=$(cat /run/secrets/NPM_TOKEN) npm ci.
kapapra.toml — Kapapra docs