Build Pipeline

Updated Jan 21, 2026 Edit this page

Build Pipeline

ACT features a smart build pipeline that can automatically detect and build your application from source, even without a Dockerfile.

Build Logic

When you deploy a service, ACT follows this logic to determine how to build your image:

  1. Manual Override: If you provided specific dockerfile_content via API, use it.
  2. User Dockerfile: Check if a Dockerfile exists in the repo root (or context_path).
  3. Nixpacks Auto-Detection: If no Dockerfile is found, ACT uses Nixpacks to analyze your code and generate a build plan.
[Start Deployment]
Has 'dockerfile' content in API? ─── Yes ──► [Build Custom Dockerfile]
       No
Has Dockerfile in Repo? ──────────── Yes ──► [Build User Dockerfile]
       No
[Run Nixpacks Analysis] ────────────► [Generate Plan] ──► [Build Image]

Nixpacks Auto-Detection

ACT uses Nixpacks (v1.29.1) to automatically build the following project types:

  • Node.js: Detects package.json
  • Python: Detects requirements.txt, poetry.lock, or Pipfile
  • Go: Detects go.mod
  • Rust: Detects Cargo.toml
  • Java/Kotlin/Scala: Detects pom.xml or build.gradle
  • PHP: Detects composer.json
  • Static Sites: HTML/CSS/JS

Customizing Auto-Builds

You can customize the Nixpacks build by setting environment variables in your Service configuration:

  • NIXPACKS_BUILD_CMD: Override the build command (e.g., npm run build:prod)
  • NIXPACKS_START_CMD: Override the start command (e.g., node dist/main.js)
  • NIXPACKS_PKGS: Install additional system packages (e.g., ffmpeg, imagemagick)

Docker-in-Docker (DinD) Support

ACT’s builder is optimized to run on remote servers. It handles the complexities of “Docker-in-Docker” builds automatically:

  • Local Cache: Uses /var/lib/act/build-cache on the server to speed up repeated builds.
  • Registry Cache: Pushes build cache layers to your container registry for multi-server performance.
  • Multi-Arch: Supports building amd64 and arm64 images using QEMU emulation if needed.