wwwwwwwwwwwwwwwwwww

Releasing

Full CI/CD pipeline for builds, tests, and deployment

Takeout includes a complete release pipeline that runs checks, tests, builds, deploys, and monitors—all in one command. It’s highly parallel and typically finishes a full end-to-end release in 5-10 minutes.

bun run ci

This runs the full pipeline: type checking, linting, unit tests, web build, integration tests, deployment, and post-deploy health monitoring.

How It Works

The pipeline runs tasks in parallel where possible:

  1. Parallel phase: checks, playwright install, unit tests, web build all run concurrently
  2. Integration tests: run against the production build
  3. Deploy: pushes to your configured platform (uncloud or SST)
  4. Health check: monitors services until healthy, then tails logs

The parallelism is why it’s fast. Checks don’t block the build. Unit tests run while playwright installs. Everything that can overlap does.

Flags

Skip parts of the pipeline when you need to:

Flag

What it does

--dry-run

Run everything except deploy (alias for --skip-deploy)

--skip-checks

Skip type checking and linting

--skip-tests

Skip unit and integration tests

--skip-build

Skip the web build

--skip-web-build

Skip web build but run other build steps

--skip-deploy

Run checks/tests/build but don’t deploy

--dev

Use dev server instead of production build (faster iteration)

--redeploy

Skip checks, tests, and build—just deploy

Common Workflows

Test locally before pushing:

bun run ci --dry-run

Runs the full pipeline without deploying. Catches issues before they hit CI.

Quick redeploy after config change:

bun run ci --redeploy

Skips everything and just deploys. Useful when you’ve only changed environment variables or infrastructure config.

Fast iteration on tests:

bun run ci --skip-checks --dev

Skips type checking and uses the dev server instead of a production build. Faster feedback loop when debugging test failures.

Post-Deploy Monitoring

After deployment, the pipeline automatically monitors your services:

  1. Waits for containers to start (web, zero, minio)
  2. Checks Docker health status on each container
  3. Hits the /api/health endpoint to verify the app responds
  4. Requires 2 consecutive healthy checks for stability
  5. Tails recent logs so you can see startup output
  6. Times out after 5 minutes if services don’t stabilize

If something fails, you get container logs and SSH instructions for debugging.

Deployment Platforms

The pipeline auto-detects your deployment platform from environment variables:

  • uncloud: Uses DEPLOY_HOST and DEPLOY_DB
  • SST: Falls back if uncloud isn’t configured

Set DEPLOYMENT_PLATFORM=uncloud or DEPLOYMENT_PLATFORM=sst in .env.production to be explicit.

CI Integration

The same command runs in GitHub Actions. The pipeline handles:

  • AWS credential setup
  • SSH key configuration for uncloud
  • Playwright browser installation
  • Docker cleanup on exit

Secrets are read from GitHub environment variables. Run bun tko env sync-to-github to push your local .env.production to GitHub secrets.

Edit this page on GitHub.