Building Nodes
About 882 wordsAbout 3 min
Cloud-native builds distribute tasks to build nodes for execution, using Docker images as the build environment.
Configuration Method
Use pipeline.runner.tags to specify the build node, and pipeline.runner.cpus to configure the CPU core count.
Available Nodes
| Tags | Architecture | CPU Cores | GPU Memory | Build Max Time | Dev Max Time |
|---|---|---|---|---|---|
cnb:arch:amd64 | amd64 | 1 ~ 64 (default 8) | - | 20 hours | 18 hours |
cnb:arch:arm64:v8 | arm64/v8 | 1 ~ 16 (default 8) | - | 20 hours | 18 hours |
cnb:arch:amd64:gpu | amd64 | Fixed 16 | 48GB (shared) | 4 hours | 4 hours |
cnb:arch:amd64:gpu:H20 | amd64 | Fixed 32 | 96GB (shared) | 4 hours | 4 hours |
cnb:arch:amd64:gpu:L40 | amd64 | Fixed 16 | 48GB (shared) | 4 hours | 4 hours |
Warning
cnb:arch:amd64:gpu:H20 is not recommended as H20 has been discontinued.
Example
main:
push:
- runner:
tags: cnb:arch:amd64
cpus: 8
stages:
- name: uname
script: uname -a
- runner:
tags: cnb:arch:arm64:v8
cpus: 8
stages:
- name: uname
script: uname -a
$:
vscode:
- runner:
tags: cnb:arch:amd64:gpu
services:
- vscodeRoot-Organization Custom Runners
In addition to the platform-provided build nodes, root-organization administrators can self-attach Mac and Windows build machines as resources dedicated to the organization, supporting use cases such as iOS builds or Windows desktop packaging.
Connecting a Build Machine
- Open
Root Organization / Organization Settings / Build Nodes, click+ Add Runner, fill in the name and tags, and save. - The new node starts in the
Offlinestate. Click theConnection Guidebutton at the end of the row; the dialog shows a one-click setup script for each platform (Mac, Windows) with the node's unique identifier already injected — no manual replacement is required. - Run the script for the matching platform on the target Mac/Windows build machine. The node turns
Onlineonce it successfully connects.
Using It in .cnb.yml
Once the node is online and enabled, schedule pipelines onto it via runner.namespace plus runner.tags:
- Set
runner.namespacetogroupto use the self-hosted nodes attached to the root organization that owns the current repository. runner.tagsmust be a subset of the tags declared on the node (an AND match — every tag listed must appear on the node). For example, when the node is tagged[mac, arm64, xcode15], usingtags: [mac, arm64]will match.
Mac Node Example
main:
push:
- runner:
# Use a self-hosted runner under the root organization the current repo belongs to
namespace: group
# Each listed tag must be present on the node's labels (node labels form a superset)
# e.g. when the node is tagged [mac, arm64, xcode15], the following will match
tags:
- mac
- arm64
stages:
- name: build-on-mac
script: |
# Show system info (verify we are running on a mac node)
sw_vers
uname -m
# Common build tools (print versions if installed; missing ones do not fail the pipeline)
command -v xcodebuild >/dev/null && xcodebuild -version || echo "xcodebuild not installed"
command -v brew >/dev/null && brew --version || echo "brew not installed"Windows Node Example
main:
push:
- runner:
# Use a self-hosted runner under the root organization the current repo belongs to
namespace: group
# Each listed tag must be present on the node's labels (node labels form a superset)
# e.g. when the node is tagged [windows, win11, msvc2022], the following will match
tags:
- windows
stages:
- name: build-on-windows
script: |
# Show system info (verify we are running on a windows node)
# Note: on self-hosted Windows runners, stage scripts default to PowerShell.
# `ver` is a cmd built-in, so invoke it via `cmd /c`.
cmd /c ver
systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
# git is a required dependency for self-hosted windows runners
git -vLimitations
- Only Mac and Windows build machines are supported.
- The custom build machine must be able to reach the CNB site (for node registration, heartbeat reporting, pulling pipeline tasks, and uploading logs/artifacts). If the machine sits on an internal network, make sure the required egress policy is in place.
- Custom Runners do not enable Docker by default; build scripts run directly on the host. As a result:
runner.cpushas no effect (resource limits are enforced via Docker cgroups; without Docker, the full host capacity is available) and is not counted as core-hour usage.- Docker-image-based build environments (
pipeline.docker.image, etc.) are not effective. OverlayFSis unavailable, so second-read clones automatically fall back to plaingit clone.
- Custom Runners are for Cloud Native Build only and cannot be used for Workspaces (remote development) tasks.
- When a pipeline targets this Runner and the picked node is temporarily unavailable (offline, temporarily disabled, or resource usage has reached the limits configured by the node administrator, e.g. CPU / memory, concurrent pipeline count), the system automatically tries to re-allocate to another available node. The pipeline fails if no other available node can be assigned.
Tips
If Build Nodes is not visible under Root Organization / Organization Settings, this capability has not been enabled for your organization yet — please contact the platform administrator.