Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
338 commits
Select commit Hold shift + click to select a range
7e21f0e
chore: add test-docker, test-all, test-vm targets to root justfile
sigma Feb 6, 2026
a73fb91
refactor: use build tags instead of env vars for integration tests
sigma Feb 6, 2026
e0f8d8a
fix: VM test - systemd-machined is socket-activated
sigma Feb 6, 2026
b850115
fix: VM test - use --help instead of --version
sigma Feb 6, 2026
2bdff05
refactor: move VM integration test to root flake
sigma Feb 6, 2026
fb826a0
refactor: extract VM integration test to separate file
sigma Feb 6, 2026
e21d850
fix: suppress 'system' deprecation warning in VM test
sigma Feb 6, 2026
c4ef47e
test: expand VM integration tests and fix nix config bugs
sigma Feb 6, 2026
100ac3d
refactor: use Go templates for Nix config generation
sigma Feb 6, 2026
1a102bd
test: add shell-based integration test framework
sigma Feb 6, 2026
364e957
fix: use path reference instead of hardcoded API key in example
sigma Feb 6, 2026
c00eccb
feat(nix): add host config directory mounting options
sigma Feb 6, 2026
f048a96
feat(config): add host config directory fields to AgentConfig
sigma Feb 6, 2026
cc48323
feat(generator): add bind mounts for agent config directories
sigma Feb 6, 2026
3298ce0
docs: document host config directory mounting
sigma Feb 6, 2026
9959e8a
refactor: delegate Go tasks from root justfile to packages/forage-ctl
sigma Feb 6, 2026
41b9a35
chore: update go dependencies
sigma Feb 6, 2026
824d380
feat: make secret-based auth optional for credential-mount agents
sigma Feb 6, 2026
24a98cd
fix(nix): make state directories accessible to configured user
sigma Feb 6, 2026
fea3725
fix: skip secrets setup when no agents use secrets
sigma Feb 6, 2026
4434c93
feat(sandbox): add SSHKeys field to CreateOptions
sigma Feb 6, 2026
5654479
feat(sandbox): add dynamic SSH key resolution
sigma Feb 6, 2026
bb23cb2
feat(cli): add --ssh-key flag to up command
sigma Feb 6, 2026
02b0936
fix(app): set container prefix when initializing runtime
sigma Feb 6, 2026
53da3c1
refactor(ssh): change from port-based to host-based connections
sigma Feb 6, 2026
6717fe7
refactor(config,port): remove Port field, add ContainerIP() helper
sigma Feb 6, 2026
e436b13
refactor(generator): remove forwardPorts and Port field
sigma Feb 6, 2026
a6d106c
refactor(health): change from port to host parameter
sigma Feb 6, 2026
1b40569
refactor(runtime): remove SSHPort, use container IP
sigma Feb 6, 2026
f558712
refactor: remove port forwarding, use container IPs directly
sigma Feb 6, 2026
34d08bc
feat(sandbox): map host UID/GID to container agent user
sigma Feb 6, 2026
0de723b
feat(sandbox): mount host tmux config, fix UID resolution
sigma Feb 6, 2026
988f314
feat(sandbox): mount host shell configuration in containers
sigma Feb 6, 2026
44e5eea
refactor(sandbox): force bash for agents, fix .config ownership
sigma Feb 6, 2026
1f0b145
feat(sandbox): mount .claude/ for jj/git-worktree, add --no-tmux-conf…
sigma Feb 7, 2026
6929777
feat(sandbox): force bash as container login shell
sigma Feb 7, 2026
f6307de
refactor(generator): replace hardcoded mounts with policy maps
sigma Feb 7, 2026
e3bf34a
refactor(sandbox): auto-detect VCS backend, simplify CLI flags
sigma Feb 7, 2026
ea7e98b
feat(config): add AgentPermissions struct and validation
sigma Feb 7, 2026
b4ef9b1
feat(generator): add permissions policy interface and Claude implemen…
sigma Feb 7, 2026
7eccc42
feat(sandbox): mount ~/.claude.json into container
sigma Feb 7, 2026
1ccbbfa
feat(generator): add PermissionsMount support to container config
sigma Feb 7, 2026
6520fef
feat(sandbox): generate agent permissions files during creation
sigma Feb 7, 2026
4e6a897
feat(modules): add permissions option to NixOS agent config
sigma Feb 7, 2026
a2011dc
docs: document agent permissions in templates, config, and security
sigma Feb 7, 2026
6b18e10
feat(tui): add grouped list infrastructure
sigma Feb 7, 2026
097cb19
feat(tui): add creation wizard, screen routing, and grouped list inte…
sigma Feb 7, 2026
77e8563
fix(config): harden ListSandboxes to skip non-metadata JSON files
sigma Feb 7, 2026
7025c56
fix(sandbox): remove permissions files during cleanup
sigma Feb 7, 2026
7d9e822
feat(cmd): add `forage-ctl gc` for sandbox garbage collection
sigma Feb 7, 2026
4619763
fix(cmd): remove dead "dir" mode fallback in ps.go
sigma Feb 7, 2026
cb300b2
config: add AgentIdentity struct to HostConfig and SandboxMetadata
sigma Feb 9, 2026
7e7a3ca
sandbox: add identity fields to CreateOptions
sigma Feb 9, 2026
1156360
sandbox: resolve and validate agent identity during creation
sigma Feb 9, 2026
a7adb0e
generator: emit agent identity config and SSH key bind mounts
sigma Feb 9, 2026
250f3ec
cmd/tui: add identity CLI flags, wizard fields, status display
sigma Feb 9, 2026
ccf32b0
skills/nix: include identity in generated CLAUDE.md and host module
sigma Feb 9, 2026
62872f5
test: add agent identity test coverage
sigma Feb 9, 2026
68fdbdd
chore: add .claude to .gitignore
sigma Feb 9, 2026
46a42c7
skills: move system prompt and skill rendering to templates
sigma Feb 9, 2026
98d5d98
generator: create tmux windows per agent at sandbox start
sigma Feb 9, 2026
ea11893
multiplexer: add Multiplexer interface abstraction
sigma Feb 10, 2026
effa9a8
config: add Multiplexer field to Template and SandboxMetadata
sigma Feb 10, 2026
ab9aedd
generator: use multiplexer abstraction for container config
sigma Feb 10, 2026
65ae4a0
health: generalize checks to use multiplexer interface
sigma Feb 10, 2026
84ba655
skills: replace TmuxSession with MuxInstructions
sigma Feb 10, 2026
98490b6
sandbox: rename NoTmuxConfig to NoMuxConfig, store Multiplexer
sigma Feb 10, 2026
299b0d3
ssh,gateway: dispatch on multiplexer type for connections
sigma Feb 10, 2026
8bb80a7
skills: rewrite nix skill with ad-hoc packages and troubleshooting
sigma Feb 10, 2026
d250f20
registry: pin nixpkgs to local store path via pkgs.path
sigma Feb 10, 2026
f0841de
fix: sanitize json generation
sigma Feb 10, 2026
1c7dbc3
multiplexer: add AttachCommandCC for tmux control mode
sigma Feb 10, 2026
1b71621
terminal: add WezTerm version detection for tmux control mode
sigma Feb 10, 2026
4996e47
ssh: use tmux -CC control mode when WezTerm is detected
sigma Feb 10, 2026
1ee0438
docs: fix CLI reference to match actual implementation
sigma Feb 11, 2026
042952a
multiplexer: auto-detect tmux control mode in AttachCommand
sigma Feb 11, 2026
678bcda
config: propagate jj identity to sandboxes
sigma Feb 11, 2026
e7555e4
injection: create package with interfaces and types
sigma Feb 11, 2026
9bb7d41
reproducibility: create package with Nix implementation
sigma Feb 11, 2026
0fd0797
runtime: add ContainerInfo and MountGeneratedFile interface
sigma Feb 11, 2026
c437629
multiplexer: implement contribution interfaces
sigma Feb 11, 2026
3315c60
workspace: implement contribution interfaces
sigma Feb 11, 2026
701af4e
agent: create package with Claude implementation
sigma Feb 11, 2026
527bbd5
injection: create infrastructure contributors
sigma Feb 11, 2026
fb1e5db
injection: create collector for contributions
sigma Feb 11, 2026
a0a19d5
sandbox: integrate injection collector into creator
sigma Feb 11, 2026
a4e5fb6
generator: refactor container.go to use contributions
sigma Feb 11, 2026
2f0871a
reproducibility: add MountContributor interface
sigma Feb 11, 2026
e73bb1e
generator: receive multiplexer instance instead of string type
sigma Feb 11, 2026
9df270c
generator: complete migration to contribution-based config
sigma Feb 11, 2026
3991384
generator: fix Nix syntax error from unescaped identity strings
sigma Feb 11, 2026
7a385a6
generator: use pname instead of outPath for agent package references
sigma Feb 11, 2026
b232b26
generator: allow unfree packages in sandbox containers
sigma Feb 11, 2026
7273b0e
sandbox: fix relative paths in generated file bind mounts
sigma Feb 11, 2026
e7ab1ab
sandbox: mount .git directory alongside .jj for jj workspaces
sigma Feb 11, 2026
2e03c2d
sandbox: pass --nixpkgs-path to extra-container create
sigma Feb 12, 2026
dc78114
module: replace deprecated pkgs.system with stdenv.hostPlatform.system
sigma Feb 12, 2026
57a091c
module: use nixpkgs flake input for nixpkgsPath instead of pkgs.path
sigma Feb 12, 2026
b5eccf5
ssh: avoid double tmux -CC invocation in control mode attach
sigma Feb 12, 2026
6d97d9c
ssh: fix tmux control mode hang on exit by dropping exec
sigma Feb 12, 2026
d4bcd36
agent: enable experimental agent teams in all Claude sandboxes
sigma Feb 12, 2026
07d1cfa
decouple container names from sandbox names
sigma Feb 12, 2026
63676a8
store runtime type in sandbox metadata
sigma Feb 12, 2026
50a42b3
add /etc/forage.json inside nspawn containers
sigma Feb 12, 2026
50b2614
add labels to Docker/Podman containers for orphan detection
sigma Feb 12, 2026
8f7a2f9
add nspawn List() fallback via in-container forage.json
sigma Feb 12, 2026
9bfa7d3
improve GC orphan detection with recovered sandbox names
sigma Feb 12, 2026
9601938
remove dead InitCommands code from injection system
sigma Feb 12, 2026
f7272c0
remove dead generator/permissions.go code
sigma Feb 12, 2026
de2c637
warn on unresolvable packages instead of silent skip
sigma Feb 12, 2026
19230e7
validate SecretName format in AgentConfig
sigma Feb 12, 2026
e73aac1
extend MockRuntime to implement GeneratedFileRuntime
sigma Feb 12, 2026
2c3f67a
document EnvVar.Value format contract
sigma Feb 12, 2026
b164773
add read-only workspace mode for filesystem-level enforcement
sigma Feb 12, 2026
8b64316
fix gofmt alignment in pick.go, agent.go, and nix.go
sigma Feb 12, 2026
520ce42
fix variable shadowing warnings in tests and creator
sigma Feb 12, 2026
e706e2e
fix unused write to Action field in picker test
sigma Feb 12, 2026
8338573
remove always-nil error return from parseCreateOptions
sigma Feb 12, 2026
2d8acaa
remove unused isHeaderSelected function
sigma Feb 12, 2026
d48efc4
remove redundant gofmt CI step, already covered by golangci-lint
sigma Feb 12, 2026
58a5673
emit nixfmt-compatible Nix from the Go generator
sigma Feb 12, 2026
b8d2bf8
fix gofmt alignment in config.go, container.go, and templates.go
sigma Feb 12, 2026
dadefc8
switch to nixfmt-tree for directory-level Nix formatting
sigma Feb 12, 2026
0c326ba
fix flaky tmux attach command test for control-mode environments
sigma Feb 12, 2026
3f2263e
Add comprehensive codebase audit report (2026-02-12)
sigma Feb 12, 2026
9dbd2f4
SEC-C1: remove passwordless sudo for container agent user
sigma Feb 12, 2026
f227f10
SEC-C2: add file locking for concurrent sandbox operations
sigma Feb 12, 2026
4fbcd9a
SEC-C3: prevent symlink following in generated file staging
sigma Feb 12, 2026
1be782b
SEC-C4: validate proxy target URL scheme to prevent SSRF
sigma Feb 12, 2026
b998532
SEC-C5: filter host environment in syscall.Exec calls
sigma Feb 12, 2026
f342fc7
SEC-H1: remove wildcard CORS header from proxy
sigma Feb 12, 2026
15d9629
SEC-H2: use only X-Api-Key header for auth injection
sigma Feb 12, 2026
73fd839
SEC-H3: restrict state directory permissions to 0750
sigma Feb 12, 2026
ef90f9f
SEC-H4: restrict config file permissions to hide secret paths
sigma Feb 12, 2026
f5c0af7
SEC-H5: make cleanup failures visible with proper logging
sigma Feb 12, 2026
aca239e
SEC-H6: use nftables for air-gap (none) network mode
sigma Feb 12, 2026
0fdd11e
SEC-M6: clean up generated file staging directories during cleanup
sigma Feb 12, 2026
7e673b1
ARCH-M1: fix commands bypassing paths() helper
sigma Feb 12, 2026
e9dc19f
ARCH-L1: remove dead code in ps.go
sigma Feb 12, 2026
16c9d5b
ARCH-L2: quote first argument in exec.go shellQuote
sigma Feb 12, 2026
fdef8c6
ARCH-L4: use filepath.Join with safePath in reset.go
sigma Feb 12, 2026
2a51a0c
SEC-M3: fix misleading comment about secret visibility
sigma Feb 12, 2026
e5e7a51
DOC: update stale documentation across DESIGN.md, security.md, and co…
sigma Feb 12, 2026
c535806
Fix tests broken by SEC-C4, SEC-H2, and SEC-H6 changes
sigma Feb 12, 2026
d1e39a3
SEC-L1: add periodic cleanup to rate limiter to prevent memory leak
sigma Feb 12, 2026
067e3b9
SEC-L2: redact SSH key file paths from debug logs
sigma Feb 12, 2026
9e354b0
SEC-L3: deduplicate tmpfiles rule for /home/agent/.config
sigma Feb 12, 2026
4224bc8
SEC-M1: add size-based audit log rotation
sigma Feb 12, 2026
0f4d457
SEC-M5: add defensive validation in workspace backend interface
sigma Feb 12, 2026
072895b
ARCH-L3: make proxy API key filename configurable
sigma Feb 12, 2026
168fe79
DOC-L2: update skill injection docs to reflect current capabilities
sigma Feb 12, 2026
6b66914
DOC: fix outdated DESIGN.md module references and stateless claim
sigma Feb 12, 2026
3502dc8
SEC-H7: document DNS resolution timing limitation in restricted mode
sigma Feb 12, 2026
492bad7
SEC-M4: implement proxy sandbox identity verification via source IP
sigma Feb 12, 2026
73cd7c5
SEC-M2: add assertion that secrets directory is on tmpfs
sigma Feb 12, 2026
25a945d
FEAT-1,2,3,4: capabilities interface, resource limits, graceful shutd…
sigma Feb 12, 2026
9c34e75
FEAT-5: health monitoring daemon
sigma Feb 12, 2026
f92f44b
FEAT-6: sandbox state snapshots; fix lint, fmt, and test issues
sigma Feb 12, 2026
9080038
fix: formatting issue in host.nix
sigma Feb 12, 2026
9893419
chore: remove obsolete audit docs
sigma Feb 12, 2026
388e4e3
Add MIT License to the project
sigma Feb 12, 2026
92917a4
Remove status section from README
sigma Feb 12, 2026
ad5f946
fix: config.json permissions and secret handling
sigma Feb 20, 2026
3e63f23
fix: disable tmux automatic-rename to prevent wezterm tab title flicker
sigma Feb 20, 2026
5102492
refactor: consolidate shell quoting with go-shellquote
sigma Feb 20, 2026
d63b738
refactor: consolidate workspaceBackendFor into workspace package
sigma Feb 20, 2026
3fce75e
refactor: replace safePath with filepath-securejoin, delete no-op nor…
sigma Feb 20, 2026
c809c73
chore: add TODO annotations for AGENTS.md detection and skills.nix ag…
sigma Feb 20, 2026
cbcb0b9
refactor: architecture/placement cleanups (wezterm connect, claude tm…
sigma Feb 20, 2026
d668512
refactor: replace hand-rolled git/jj config parsers with git CLI and …
sigma Feb 20, 2026
ea86592
refactor: centralize picker/connection flow into gateway.Connect
sigma Feb 20, 2026
a0a3363
refactor: template-ize nftables and dnsmasq config generation
sigma Feb 20, 2026
0a5235e
refactor: add LogViewer interface and fix shell command description
sigma Feb 20, 2026
1582063
refactor: make hardcoded values configurable (network prefix, usernam…
sigma Feb 20, 2026
13d1601
fix: update vendorHash and add git/jj to nativeCheckInputs for nix build
sigma Feb 20, 2026
b522cbc
fix: replace filepath-securejoin with lexical path validation
sigma Feb 20, 2026
f22db2b
fix: always run extra-container destroy during cleanup to remove unit…
sigma Feb 20, 2026
a0a2a86
fix: patch extra-container for nixos-init compat with latest nixpkgs-…
sigma Feb 20, 2026
f6e4e84
style: reformat patchedExtraContainer nix expression
sigma Feb 20, 2026
0737405
fix: replace bash -c with writeShellScript for identity service
sigma Feb 20, 2026
21b97db
fix: use jj/git CLI for identity resolution instead of file parsing
sigma Feb 20, 2026
0e65f4b
fix: update vendorHash after removing BurntSushi/toml dependency
sigma Feb 20, 2026
f412f32
fix: make identity tests hermetic for nix build sandbox
sigma Feb 20, 2026
7e04eec
fix: set HOME in process env for jj identity tests
sigma Feb 20, 2026
06a8056
fix: use Nix interpolation for store paths in identity script
sigma Feb 20, 2026
f4f6a69
feat: add initCommands option to template config
sigma Feb 20, 2026
3185a19
feat: add InitCommandResult type and wire into CreateResult
sigma Feb 20, 2026
98dbdc6
feat: implement runInitCommands and integrate into Create()
sigma Feb 20, 2026
b5b042c
feat: display init command results in up and pick commands
sigma Feb 20, 2026
864c56f
test: add tests for initCommands config and creator logic
sigma Feb 20, 2026
7417f74
docs: document initCommands and per-project .forage/init
sigma Feb 20, 2026
fa62988
ci: add GitHub Actions workflow to deploy docs to GitHub Pages
sigma Feb 20, 2026
fa9dbba
fix: nix formatting issues
sigma Feb 20, 2026
5b33581
feat: add beads-rust and beads-viewer from toolbox to devShell
sigma Feb 21, 2026
74bf6ce
config: add WorkspaceMount and WorkspaceMountMeta types
sigma Feb 21, 2026
31f737e
options: add Repos map to CreateOptions for named repo parameters
sigma Feb 21, 2026
e4e9803
injection: add WorkspaceMountsContributor for multi-mount support
sigma Feb 21, 2026
a3597a5
creator: implement setupWorkspaceMounts for composable mounts
sigma Feb 21, 2026
56af5c2
contributions: wire up multi-mount contributor and per-mount VCS back…
sigma Feb 21, 2026
728dc56
cleanup: iterate WorkspaceMounts for multi-mount cleanup
sigma Feb 21, 2026
ec4e107
cli: make --repo repeatable and optional for template-specified mounts
sigma Feb 21, 2026
6891aa7
nix: add workspace.mounts and workspace.useBeads to template options
sigma Feb 21, 2026
78e8fd6
skills: update system prompt and skill generation for composite mounts
sigma Feb 21, 2026
b2a2708
test: add tests for composable workspace mounts
sigma Feb 21, 2026
5efd7f4
docs: add comprehensive documentation for composable workspace mounts
sigma Feb 21, 2026
203ac00
fix: clean up formatting
sigma Feb 21, 2026
c15b446
fix: use ArgsLenAtDash for exec command argument parsing
sigma Feb 24, 2026
3dbaeab
feat: add E2E testing infrastructure with full-lifecycle VM tests
sigma Feb 24, 2026
9a8f46a
feat: add Go E2E framework with System interface and VMSystem
sigma Feb 25, 2026
022587c
feat: add TestEnv and assertion helpers for E2E tests
sigma Feb 25, 2026
0b0519e
feat: reimplement E2E test scenarios in Go
sigma Feb 25, 2026
7ba0312
build: update nix integration for Go E2E tests
sigma Feb 25, 2026
dc53261
refactor: remove bash E2E test scripts
sigma Feb 25, 2026
e6be168
test(e2e): add templates command verification to TestModuleSetup
sigma Feb 25, 2026
c246f98
test(e2e): add secrets, network isolation, and audit log verification
sigma Feb 25, 2026
d8b72d9
test(e2e): add stop/start, reset, and cleanup verification
sigma Feb 25, 2026
d97e003
test(e2e): add garbage collection test
sigma Feb 25, 2026
fcef5e0
perf(e2e): parallelize read-only subtests across all test functions
sigma Feb 25, 2026
b0dd9c1
fix: make sandbox secrets readable by container agent user
sigma Feb 25, 2026
206acec
fix: use extra-container to restart stopped nspawn containers
sigma Feb 25, 2026
ebca085
fix(e2e): correct status and secrets assertions to match actual behavior
sigma Feb 25, 2026
8109d9d
fix: nix formatting
sigma Feb 25, 2026
8e1de21
chore: ignore local env files
sigma Feb 25, 2026
9a0d988
feat(e2e): add local E2E mode and graceful skip in testenv
sigma Feb 25, 2026
1d2976c
feat: add test-e2e-local target and enhance check with conditional e2e
sigma Feb 25, 2026
98fbd28
feat: add internal/telemetry package with OTel init and span helpers
sigma Feb 25, 2026
de7501b
feat(e2e): instrument test framework with OpenTelemetry spans
sigma Feb 25, 2026
e4c3d2c
feat: instrument production CLI and runtime with OpenTelemetry spans
sigma Feb 25, 2026
708f923
chore: update nix vendorHash for OTel dependencies
sigma Feb 25, 2026
1e3830d
chore: load optional local environment file
sigma Feb 25, 2026
7ff2757
fix(e2e): improve trace quality with context threading and span attri…
sigma Feb 25, 2026
ba16812
feat: propagate trace context across process boundaries via TRACEPARENT
sigma Feb 25, 2026
a186596
feat: add granular spans to container creation workflow
sigma Feb 25, 2026
4e767f5
refactor: replace context.Background() with caller-inherited context
sigma Feb 25, 2026
8ef5c01
feat: add nix build observability to nspawn container creation
sigma Feb 25, 2026
269ff94
perf: replace pkgs.path with literal store path in container nix config
sigma Feb 25, 2026
743dbaa
feat: add CachedEtcPath field to SandboxMetadata for fast restart
sigma Feb 25, 2026
68ce3cd
feat: add nixcache package for template system cache management
sigma Feb 25, 2026
3cb2003
feat: add slot-independent network config for cached inner system
sigma Feb 25, 2026
ed4a958
feat: add inner/outer NixOS config templates and generator functions
sigma Feb 25, 2026
dba1556
feat: add two-phase build methods to nspawn runtime
sigma Feb 25, 2026
3c38925
feat: add cached two-phase creation flow to sandbox creator
sigma Feb 25, 2026
388ed90
test: add tests for inner/outer config generation
sigma Feb 25, 2026
cbbf786
fix: use extra-container natively for outer config instead of broken …
sigma Feb 25, 2026
c5e806e
debug: surface nixcache diagnostics in E2E test output
sigma Feb 25, 2026
f164d4c
feat: bypass extra-container eval for outer config via custom eval-co…
sigma Feb 26, 2026
6bca75b
test: parallelize multi-sandbox creation and clean up debug logs
sigma Feb 26, 2026
d2e0b30
ci: use merge queue for e2e tests, drop push-to-main trigger
sigma Feb 26, 2026
28a4d63
fix: resolve variable shadow lint warnings in creator and nspawn
sigma Feb 26, 2026
f6bb3a2
ci: fail-fast pipeline with shared setup-nix composite action
sigma Feb 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
dotenv_if_exists .env.local
use flake
9 changes: 9 additions & 0 deletions .github/actions/setup-nix/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: Setup Nix
description: Install Nix with nixpkgs-unstable channel

runs:
using: composite
steps:
- uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-unstable
65 changes: 65 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: CI

on:
pull_request:
branches: [main]
merge_group:

jobs:
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup-nix

- name: Check Nix formatting
run: nix fmt -- --ci .

lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup-nix

- name: Run linter
run: nix develop --command bash -c "cd packages/forage-ctl && golangci-lint run"

build:
needs: [format, lint]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup-nix

- name: Build forage-ctl
run: nix build .#forage-ctl

- name: Build docs
run: nix build .#docs

test:
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup-nix

- name: Run tests
run: nix develop --command bash -c "cd packages/forage-ctl && go test ./..."

e2e:
needs: [test]
if: github.event_name == 'merge_group'
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup-nix

- name: Enable KVM
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666"' | sudo tee /etc/udev/rules.d/99-kvm.rules
sudo udevadm control --reload-rules && sudo udevadm trigger --name-match=kvm

- name: Run E2E tests
run: nix run .#e2e-driver -- 2>&1
44 changes: 44 additions & 0 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Deploy docs to GitHub Pages

on:
push:
branches: [main]

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: pages
cancel-in-progress: false

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install Nix
uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-unstable

- name: Build docs
run: nix build .#docs

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: result

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
15 changes: 15 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
result
result-*
.direnv/
docs/book/

# Go vendor directories (dependencies managed by Nix)
**/vendor/

.claude/

# E2E test VM disk images
*.qcow2

# local environment files
.*.local
Loading