Build and deploy with a familiar syntax

From the Latin "andō" - to set in motion.

ANDO is a continous integration tool that runs your build and deployment workflow inside a Docker container. C# like syntax, support for .NET, Node, Npm, Cloudflare and more.

Getting started

Install as a dotnet tool.

shell
# Install ANDO
dotnet tool install -g ando

# Create a hello world build script
echo 'Log.Info("Hello, World!");' > build.ando

# Run the build script
ando run

ANDO commands

The CLI provides a small, focused surface area.

Command Description
ando Run the build script (same as 'ando run').
ando run Run the build script in a Docker container.
ando verify Check build script for errors without executing.
ando clean Remove artifacts, temp files, and containers.
ando help Show available commands and options.

See the CLI reference for all options.

Example build.ando

A single C# file defines projects, tools, workflow settings, and operations.

build.ando
// Project and directory references
var WebApi = DotnetProject("./src/WebApi/WebApi.csproj");
var Frontend = Directory("./frontend");

// Backend build and publish
Dotnet.Restore(WebApi);
Dotnet.Build(WebApi);
Dotnet.Test(WebApi);
Dotnet.Publish(WebApi, o => o
  .Output(Root / "artifacts" / "api"));

// Deploy backend to Azure App Service
Azure.EnsureAuthenticated();
Artifact.Zip(Root / "artifacts" / "api", Root / "artifacts" / "api.zip");
AppService.DeployWithSwap("my-webapi", Root / "artifacts" / "api.zip");

// Frontend build and deploy
Npm.Ci(Frontend);
Npm.Run(Frontend, "build");

// Deploy frontend to Cloudflare Pages
Cloudflare.EnsureAuthenticated();
Cloudflare.PagesDeploy(Frontend / "dist", "my-frontend");

All Operations

Each operation registers a deterministic step and runs inside the container.

Ando (11)

Artifacts Operations for copying build artifacts from the container to the host after the build completes.
Configuration Enum for build configuration. Returns the current configuration set via Options.UseConfiguration().
Context Provides access to build context including paths and variables. Use Context.Paths for path helpers and Context.Vars for build variables.
Directory Creates a reference to a directory. Used with Npm and Cloudflare operations. Supports path combining with the / operator.
DotnetProject Creates a reference to a .NET project file (.csproj). Used with Dotnet and Ef operations.
Log.Debug Logs a debug message. Only visible at Detailed verbosity level.
Log.Error Logs an error message. Always visible regardless of verbosity level.
Log.Info Logs an informational message. Visible at Normal and Detailed verbosity levels.
Log.Warning Logs a warning message. Visible at Minimal, Normal, and Detailed verbosity levels.
Options Build options for configuring the workflow. Set configuration, Docker image, and other build-wide settings.
Root The root path of the project (where build.ando is located). Supports path combining with the / operator.

App Service (9)

AppService.CreateSlot Create a new deployment slot.
AppService.DeleteSlot Delete a deployment slot.
AppService.DeployWithSwap Deploy to a slot then swap to production (zero-downtime).
AppService.DeployZip Deploy an app service using zip deploy.
AppService.ListSlots List deployment slots for an app service.
AppService.Restart Restart an app service.
AppService.Start Start an app service.
AppService.Stop Stop an app service.
AppService.SwapSlots Swap deployment slots.

Azure (8)

Azure.CreateResourceGroup Create a resource group if it doesn't exist.
Azure.DeleteResourceGroup Delete a resource group and all its resources.
Azure.EnsureAuthenticated Authenticate to Azure using the best available method. Checks for service principal credentials (AZURE_CLIENT_ID, AZURE_CLIENT_SECRET, AZURE_TENANT_ID), then falls back to existing CLI session or interactive login. Prompts to install Azure CLI if not available.
Azure.EnsureLoggedIn Verify the user is logged in to Azure CLI. Fails if not authenticated.
Azure.LoginWithManagedIdentity Login with Managed Identity (for Azure-hosted environments).
Azure.LoginWithServicePrincipal Login with a Service Principal (for CI/CD).
Azure.SetSubscription Set the active Azure subscription.
Azure.ShowAccount Display current Azure account information.

Bicep (4)

Bicep.Build Compile a Bicep file to ARM JSON template.
Bicep.DeployToResourceGroup Deploy a Bicep template to a resource group.
Bicep.DeployToSubscription Deploy a Bicep template at subscription scope.
Bicep.WhatIf Preview what would be deployed (what-if analysis).

Cloudflare (6)

Cloudflare.EnsureAuthenticated Verify Cloudflare credentials. Prompts interactively if environment variables are not set. See authentication for setup.
Cloudflare.PagesCreateProject Create a new Cloudflare Pages project.
Cloudflare.PagesDeploy Deploy a directory to Cloudflare Pages. The directory should be the build output folder.
Cloudflare.PagesListDeployments List deployments for a Cloudflare Pages project.
Cloudflare.PagesListProjects List all Cloudflare Pages projects.
Cloudflare.PurgeCache Purge the entire Cloudflare cache for a zone. Accepts either a Zone ID or domain name (domain is resolved automatically). Useful after deployments to ensure visitors see the latest content.

Dotnet (5)

Dotnet.Build Compile a project with optional configuration.
Dotnet.Publish Create deployment artifacts with full publish options.
Dotnet.Restore Restore NuGet packages for a project.
Dotnet.Test Run unit tests for a project.
Dotnet.Tool Create a reference to a .NET CLI tool for installation.

DotnetSdk (1)

DotnetSdk.Install Install .NET SDK globally in the container. Skips installation if already present (for warm containers).

EF Core (5)

Ef.AddMigration Create a new EF Core migration.
Ef.DatabaseUpdate Apply pending EF Core migrations to the database.
Ef.DbContextFrom Create a reference to a DbContext in a project.
Ef.RemoveMigration Remove the last migration.
Ef.Script Generate an idempotent SQL migration script.

Functions (7)

Functions.DeployWithSwap Deploy to a slot then swap to production (zero-downtime).
Functions.DeployZip Deploy a function app using zip deploy.
Functions.Publish Publish using Azure Functions Core Tools.
Functions.Restart Restart a function app.
Functions.Start Start a function app.
Functions.Stop Stop a function app.
Functions.SwapSlots Swap deployment slots.

Node (1)

Node.Install Install Node.js globally in the container. Skips installation if already present (for warm containers).

Npm (5)

Npm.Build Run 'npm run build'.
Npm.Ci Run 'npm ci' for clean, reproducible installs (preferred for CI).
Npm.Install Run 'npm install' to install dependencies.
Npm.Run Run an npm script from package.json.
Npm.Test Run 'npm test'.

62 operations