Skip to main content
Version: 0.7 (Next)

Deploying Konduit Apps

konstruct deploy takes the code in your working directory, pushes it, builds it with Cloud Native Buildpacks, and returns a live URL. No Dockerfile, no cluster, no YAML.

These are Konduit apps — the same resource the Konduit PaaS experience creates, called a ThemedApp underneath. Anything you deploy here appears in Konduit, and anything you create in Konduit can be operated from here. They are one thing with two doors.

Using Konstruct SaaS?

Konduit is available to every organization with no install step. Deploy from your browser in one click, then come back here to stream logs or set variables from your terminal.

See Konduit and Platform Themes for the full experience, the architecture behind it, and what happens when you outgrow the guardrails.

This is not the GitOps delivery model. To register a repository and promote versions through environments, see Platform commands instead — those applications never appear in Konduit.

Prerequisites

  • The CLI installed and authenticated. See CLI.
  • A Git repository with a remote your Konstruct organization can reach.

Deploy

  1. Change to your application directory:

    cd my-app
  2. Check what the CLI detects:

    konstruct detect

    It reports the language, framework, port, and repository it found. Fix anything wrong with a flag in the next step.

  3. Deploy:

    konstruct deploy

    The CLI asks for anything it cannot work out, commits and pushes your branch, then waits until the application answers and prints its URL.

To deploy without answering prompts, name everything up front:

konstruct deploy --app_name my-app --env production \
--region wc-lon1 --size s --port 8080 --yes

Useful Deploy Flags

FlagUse it to
--yesAccept defaults and never prompt. Required in CI.
--no_pushBuild the last pushed commit instead of committing your working tree.
--vars KEY=v,KEY2=v2Set environment variables at deploy time.
--replace_envReplace the application's variables instead of merging into them.
--privateDo not expose a public URL.
--no_authExpose the public URL without requiring a platform login.
--sub_path apiBuild a subdirectory, for a monorepo.
--branch mainBuild a branch other than the current one.
--followStream runtime logs once the application is live.
--replicas 3Set the replica count. Defaults to 1.

Run konstruct deploy --help for the full list.

Operate

Every command below takes the application name as --app_name, and asks when you leave it out. When your organization runs the same application in several environments, add --env.

See What Is Running

konstruct app list
konstruct app status --app_name my-app

status shows the phase, URL, current image, and recent builds.

Read Logs

konstruct app logs --app_name my-app

This follows the runtime logs until you stop it. For the build instead, when an image failed to build:

konstruct app logs --app_name my-app --build

Manage Environment Variables

konstruct app env list --app_name my-app
konstruct app env set --app_name my-app --vars DEBUG=true,LOG_LEVEL=info
note

app env set triggers a redeploy so the new values take effect.

Rebuild and Open

konstruct app redeploy --app_name my-app
konstruct app open --app_name my-app

redeploy rebuilds from the HEAD of the connected branch, which is what you want after pushing a commit outside the CLI.

Delete

konstruct app remove --app_name my-app --yes

This prunes the GitOps manifest and the workload namespace. konstruct app delete does the same thing.

Deploy from CI

Use an API key rather than a browser session, and pass --yes so nothing waits for input:

export KONSTRUCT_API_URL=https://konstruct.example.com
export KONSTRUCT_API_KEY=$KONSTRUCT_TOKEN
export KONSTRUCT_ORG=my-org

npx @konstructio/konstruct-sdk@latest deploy \
--app_name my-app --env production --no_push --yes

--no_push matters in CI: the commit is already pushed, and the runner should build that commit rather than create another.

What's Next?