Skip to content

poc: Use a unified mechanism for build, test, packaging, and release#2205

Draft
krishicks wants to merge 5 commits into
mainfrom
hicks/push-nzrkxukwuxvo
Draft

poc: Use a unified mechanism for build, test, packaging, and release#2205
krishicks wants to merge 5 commits into
mainfrom
hicks/push-nzrkxukwuxvo

Conversation

@krishicks

Copy link
Copy Markdown
Collaborator

Summary

Today, OpenShell has several overlapping sources of build and validation behavior:

  • mise defines both developer tooling (Rust and Python versions, etc), and task entry points such as mise run rust:format:check.
  • GitHub Actions owns much of the release build, packaging, and release validation logic.
  • Some release checks can only be reproduced by re-running CI, even when the underlying assertion could be run locally.

This POC starts moving those responsibilities into shared, locally runnable entry points.

The direction is:

  • Use Nix as the source of the development environment via nix develop, and eventually as the source of tools installed in the CI image.
  • Use cargo xtask as the task runner that replaces mise run over time.
  • Use Dagger for reproducible release build and packaging steps that can run locally as well as in CI.
  • Use Lima VMs for smoke tests that need realistic guest environments, such as package installation, systemd user services, rootless Podman, sandbox creation, and eventually SELinux-focused scenarios.

This PR is an incremental slice of that migration. It does not remove mise yet. Instead, it adds the first shared entry points:

  • Dagger functions for building Linux CLI binaries and assembling Debian packages. This only builds the CLI at present; it requires the gateway and driver-vm binaries to be provided.
  • A cargo xtask release-smoke-test command that accepts a provided .deb, installs it in a Lima VM, starts the packaged gateway, creates a sandbox, and verifies that undeclared network egress is denied.
  • A Release Canary job that downloads the deb-linux-amd64 artifact from the triggering Release Dev run and invokes the same xtask smoke test used locally.

The intent is that GitHub Actions increasingly orchestrates the same build and validation graph developers can run themselves, rather than being the only place that knowledge exists.

Related Issue

This is a POC implementation of #2204.

Changes

Testing

  • mise run pre-commit passes
  • Unit tests added/updated
  • E2E tests added/updated (if applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (if applicable)

krishicks added 5 commits July 9, 2026 13:36
Add a rust-native-build Dagger function that builds and stages Linux amd64 and arm64 CLI binaries using the existing CI toolchain and workflow-equivalent build steps.

Signed-off-by: Kris Hicks <khicks@nvidia.com>
Add a cargo xtask facade with mise fallback and migrate the Rust formatting
check as the first native task. This partial implementation sets the stage for
replacing mise with Nix-managed tools and native xtasks.

Signed-off-by: Kris Hicks <khicks@nvidia.com>
Add a Dagger function that assembles a Debian package using a Dagger-built CLI binary and provided gateway and VM driver binaries, mirroring the existing GitHub Actions packaging flow.

Signed-off-by: Kris Hicks <khicks@nvidia.com>
Add a cargo xtask release-smoke-test command that accepts a provided .deb package, provisions a Lima VM with rootless Podman, installs the artifact, starts the packaged gateway, creates a sandbox, and verifies that curl is denied without policy.

Signed-off-by: Kris Hicks <khicks@nvidia.com>
Add an Ubuntu rootless Podman release canary job that downloads the deb-linux-amd64 artifact from the triggering Release Dev run and runs cargo xtask release-smoke-test against it in a Lima VM.

Signed-off-by: Kris Hicks <khicks@nvidia.com>
@copy-pr-bot

copy-pr-bot Bot commented Jul 9, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant