Scale computer-use 2.0 with open-source drivers, cross-OS sandboxes, and benchmarks for training, evaluation, and data generation.
Rust agentai-agentapplecomputer-usecomputer-use-agentcontainerizationcuadesktop-automationhacktoberfestlumemacosmanusoperatorswiftvirtualizationvirtualization-frameworkwindowswindows-sandbox
cd(spaces): build the release natives on every push to main (#5230)
ddupont9982c67a04c2
diff --git a/.github/workflows/cd-cua-spaces-natives-main.yml b/.github/workflows/cd-cua-spaces-natives-main.ymlnew file mode 100644index 0000000000..651e9c236e--- /dev/null+++ b/.github/workflows/cd-cua-spaces-natives-main.yml@@ -0,0 +1,87 @@+name: "CD: Cua Spaces natives on main"++# Keeps the release's compiled native layers warm, so a cua-spaces-v* tag+# run (cd-cua-spaces.yml) restores them instead of compiling for an hour.+#+# A tag run can restore only its own tag's caches and main's (a cache saved+# by a dry run on a branch or a PR is invisible to it). This workflow builds,+# on main, exactly what cd-cua-spaces.yml's native jobs build, under the same+# cache keys and paths:+# - electron-native / electron-native-mac: .github/actions/spaces-native,+# same labels, targets and extra paths.+# The SwiftUI app's Rust slices have their own producer on main,+# ci-cua-spaces-rust-slice.yml, so they are not built here.+# Keep the two in step: a key, path or env difference makes every release a+# cache miss again. The keys are the git tree hash of the inputs (libs/cua,+# the cua-spacesd pin, the build script), so a commit with unchanged inputs+# finds its natives already saved and does nothing but restore-and-exit.+#+# Phase 0 of the build-once release model (docs/design/desktop-release-build-once-promote.md,+# CUA-1991): warm natives first, then signed artifacts on main (a separate+# workflow, phase 1), then a tag run that promotes them. This file stays+# cache-only so it can land on its own.+#+# Builds only: no secrets, no signing, no artifacts, nothing published.+# It does not run on pull requests: a PR's caches are invisible to the tag run+# and would only crowd main's out of the 10 GB cap. Use workflow_dispatch on a+# branch to try a change; the first push to main runs it for real.++on:+ push:+ branches: [main]+ paths:+ - "libs/cua/**"+ - "libs/cua-spacesd/VERSION"+ - "apps/cua-spaces-desktop/scripts/build-native.mjs"+ - ".github/actions/spaces-native/**"+ - ".github/workflows/cd-cua-spaces-natives-main.yml"+ workflow_dispatch:++permissions:+ contents: read++# One run at a time, never cancelled: a newer push waits (and replaces any+# older waiting run), so the macOS runners are not all taken by warm-ups and+# every run that starts finishes and saves.+concurrency:+ group: cd-cua-spaces-natives-${{ github.ref }}+ cancel-in-progress: false++# Same as cd-cua-spaces.yml: CUA_RELEASE_REPOSITORY is part of the native+# cache key, and rust-cache hashes the CARGO_* variables into its own key.+env:+ CARGO_NET_RETRY: "10"+ CARGO_HTTP_TIMEOUT: "120"+ CARGO_HTTP_MULTIPLEXING: "false"+ CUA_TELEMETRY: "0"+ DO_NOT_TRACK: "1"+ CUA_RELEASE_REPOSITORY: ${{ github.repository }}++jobs:+ electron-native:+ name: Electron native (${{ matrix.label }})+ runs-on: ${{ matrix.runner }}+ timeout-minutes: 180+ strategy:+ fail-fast: false+ matrix:+ include:+ - { label: win32-x64, runner: windows-latest, target: x86_64-pc-windows-msvc }+ - { label: win32-arm64, runner: windows-11-arm, target: aarch64-pc-windows-msvc }+ - { label: linux-x64, runner: ubuntu-22.04, target: x86_64-unknown-linux-gnu }+ - { label: linux-arm64, runner: ubuntu-22.04-arm, target: aarch64-unknown-linux-gnu }+ - { label: darwin-arm64, runner: macos-26, target: aarch64-apple-darwin }+ - { label: darwin-x64, runner: macos-26, target: x86_64-apple-darwin }+ defaults:+ run:+ working-directory: apps/cua-spaces-desktop+ shell: bash+ steps:+ - uses: actions/checkout@v4+ - uses: ./.github/actions/spaces-native+ with:+ label: ${{ matrix.label }}+ target: ${{ matrix.target }}+ # As electron-native-mac: the cache entry's paths are part of its+ # identity, so darwin-arm64 must list the same extra path.+ extra-paths: ${{ matrix.label == 'darwin-arm64' && 'libs/cua/target/aarch64-apple-darwin/release/libcua_spaces_ffi.dylib' || '' }}