Commit Graph

96 Commits

Author SHA1 Message Date
51f2611e9d test(wfe-kubernetes): service provider integration tests with 100% coverage 2026-04-06 18:00:01 +01:00
84686672ea feat(wfe-yaml): services block in workflow YAML definitions 2026-04-06 17:59:56 +01:00
e5db02b4f8 feat(wfe-kubernetes):
KubernetesServiceProvider for infrastructure services
2026-04-06 17:59:50 +01:00
4dfcc61143 feat(wfe): capability-based workflow routing and service lifecycle in dequeue loop 2026-04-06 17:59:44 +01:00
affcf1bca8 feat(wfe-core): add ServiceDefinition types and ServiceProvider trait 2026-04-06 17:59:38 +01:00
22d3f569df feat(wfe-yaml): add kubernetes/k8s step type with lazy
client creation
2026-04-06 17:09:23 +01:00
8f3539ed34 refactor(wfe-kubernetes): add lazy client mode for factory-based step creation 2026-04-06 17:09:11 +01:00
a9b0993ffb test(wfe-kubernetes): integration tests against Lima k3s cluster 2026-04-06 16:42:15 +01:00
6a341e426c feat(wfe-kubernetes): KubernetesStep executor (StepBody impl) 2026-04-06 16:42:09 +01:00
85a83e7580 feat(wfe-kubernetes): log streaming and resource cleanup 2026-04-06 16:42:04 +01:00
d62dc0f349 feat(wfe-kubernetes): Job manifest builder and output parsing 2026-04-06 16:41:55 +01:00
1574342e92 feat(wfe-kubernetes): scaffold crate with config, client, and namespace modules 2026-04-06 16:41:48 +01:00
2c679229db chore: add wfe-kubernetes to workspace, add kube/k8s-openapi deps 2026-04-06 16:41:36 +01:00
a4d0f2a547 fix: add version + registry to wfe-deno path dep for publishing v1.7.0 2026-04-06 13:57:56 +01:00
4b8e544ab8 chore: bump version to 1.7.0, update
CHANGELOG
2026-04-05 22:29:05 +01:00
9a08882e28 feat(wfe-deno): Deno bindings for the WFE workflow engine 2026-04-05 22:06:07 +01:00
afb91c66bd feat(wfe-core): make WorkflowBuilder steps and last_step fields public
Needed by wfe-deno to build workflow definitions via ops without
going through the pub(crate) StepBuilder constructor.
2026-04-05 22:05:04 +01:00
ead883f714 chore: bump version to 1.6.3, update CHANGELOG v1.6.3 2026-04-05 19:55:44 +01:00
ac45011794 fix(wfe-core): propagate step_name into execution pointers
Sets step_name on execution pointers when advancing to next steps,
compensation steps, and parallel branch children so that runtime
consumers can identify steps by name without lookup.
2026-04-05 19:55:12 +01:00
2b244348ca chore: bump version to 1.6.2, update CHANGELOG v1.6.2 2026-04-05 12:45:25 +01:00
de66fef2d6 feat(wfe-core): add add_step_typed() and make wire_outcome public
Adds WorkflowBuilder::add_step_typed<S>() for adding named, configured
steps directly — needed for parallel branch closures in the CLI.
Makes wire_outcome() public so callers can wire custom step graphs.
2026-04-05 12:44:00 +01:00
6c16c89379 fix: add version + registry to wfe-server path deps for publishing v1.6.1 2026-04-05 12:01:02 +01:00
e515ffbe0c chore: bump version to 1.6.1, update CHANGELOG 2026-04-05 11:55:42 +01:00
978109d3fc feat(wfe-core): add step config API for attaching runtime JSON config
Adds StepBuilder::config() to attach arbitrary JSON configuration to
individual steps, readable at runtime via context.step.step_config.
Bumps version to 1.6.1.
2026-04-05 11:52:40 +01:00
17a50d776b chore: bump version to 1.6.0, update CHANGELOG v1.6.0 2026-04-01 14:39:21 +01:00
550dcd1f0c chore: add wfe-server crates to workspace, update test contexts
Add wfe-server-protos and wfe-server to workspace members.
Update StepExecutionContext constructions with log_sink: None
in buildkit and containerd test files.
2026-04-01 14:37:40 +01:00
cbbeaf6d67 feat(wfe-server): headless workflow server with gRPC, webhooks, and OIDC auth
Single-binary server exposing the WFE engine over gRPC (13 RPCs) with
HTTP webhook support (GitHub, Gitea, generic events).

Features:
- gRPC API: workflow CRUD, lifecycle event streaming, log streaming,
  log search via OpenSearch
- HTTP webhooks: HMAC-SHA256 verified GitHub/Gitea webhooks with
  configurable triggers that auto-start workflows
- OIDC/JWT auth: discovers JWKS from issuer, validates with asymmetric
  algorithm allowlist to prevent algorithm confusion attacks
- Static bearer token auth with constant-time comparison
- Lifecycle event broadcasting via tokio::broadcast
- Log streaming: real-time stdout/stderr via LogSink trait, history
  replay, follow mode
- Log search: full-text search via OpenSearch with workflow/step/stream
  filters
- Layered config: CLI flags > env vars > TOML file
- Fail-closed on OIDC discovery failure, fail-loud on config parse errors
- 2MB webhook payload size limit
- Blocked sensitive env var injection (PATH, LD_PRELOAD, etc.)
2026-04-01 14:37:25 +01:00
6dffb91626 feat(wfe-server-protos): add gRPC service definitions for workflow server
13 RPCs in wfe.v1.Wfe service: RegisterWorkflow, StartWorkflow,
GetWorkflow, CancelWorkflow, SuspendWorkflow, ResumeWorkflow,
SearchWorkflows, PublishEvent, WatchLifecycle (stream),
StreamLogs (stream), SearchLogs, ListDefinitions.
2026-04-01 14:35:57 +01:00
c63bf7b814 feat(wfe-yaml): add log streaming to shell executor + security hardening
Shell step streaming: when LogSink is present, uses cmd.spawn() with
tokio::select! to interleave stdout/stderr line-by-line. Respects
timeout_ms with child.kill() on timeout. Falls back to buffered mode
when no LogSink.

Security: block sensitive env var overrides (PATH, LD_PRELOAD, etc.)
from workflow data injection. Proper error handling for pipe capture.

4 LogSink regression tests + 2 env var security regression tests.
2026-04-01 14:33:53 +01:00
7a9af8015e feat(wfe-core): add LogSink trait and wire lifecycle publisher into executor
LogSink trait for real-time step output streaming. Added to
StepExecutionContext as optional field (backward compatible).
Threaded through WorkflowExecutor and WorkflowHostBuilder.

Wired LifecyclePublisher.publish() into executor at 5 points:
StepStarted, StepCompleted, Error, Completed, Terminated.
Also added lifecycle events to host start/suspend/resume/terminate.
2026-04-01 14:33:27 +01:00
d437e6ff36 chore: add CHANGELOG.md for v1.5.0
Full changelog covering v1.0.0, v1.4.0, and v1.5.0 releases.
Also fix containerd integration test default address to handle
Lima socket forwarding gracefully.

879 tests passing. 88.8% coverage on wfe-rustlang.
v1.5.0
2026-03-29 17:13:14 +01:00
93f1b726ce chore: bump version to 1.5.0
Bump workspace version and all internal crate references to 1.5.0.
Add wfe-rustlang to workspace members and dependencies.
2026-03-29 17:08:41 +01:00
c58c5d3eff chore: update Lima VM config and CI pipeline for v1.5.0
Lima wfe-test VM: Alpine with system containerd + BuildKit from apk,
TCP socat proxy for reliable gRPC transport, probes with sudo for
socket permission fixes. 2 core / 4GB / 20GB.

CI pipeline: add wfe-rustlang to feature-tests, package, and publish
steps. Container tests use TCP proxy (http://127.0.0.1:2500) instead
of Unix socket forwarding. Containerd tests set WFE_IO_DIR for shared
filesystem support.
2026-03-29 16:58:03 +01:00
60e8c7f9a8 feat(wfe-yaml): wire rustlang step types and containerd integration tests
Add rustlang feature flag to wfe-yaml with support for all cargo and
rustup step types (15 total), including cargo-doc-mdx.

Schema additions: output_dir, package, features, all_features,
no_default_features, release, profile, toolchain, extra_args,
components, targets, default_toolchain fields on StepConfig.

Integration tests for compiling all step types from YAML, and
containerd-based end-to-end tests for running Rust toolchain
inside containers from bare Debian images.
2026-03-29 16:57:50 +01:00
272ddf17c2 fix(wfe-containerd): fix remote daemon support
Four bugs fixed in the containerd gRPC executor:

- Snapshot parent: resolve image chain ID from content store instead of
  using empty parent, which created rootless containers with no binaries
- I/O capture: replace FIFOs with regular files for stdout/stderr since
  FIFOs don't work across virtiofs filesystem boundaries (Lima VMs)
- Capabilities: grant Docker-default capability set (SETUID, SETGID,
  CHOWN, etc.) when running as root so apt-get and similar tools work
- Shell path: use /bin/sh instead of sh in process args since container
  PATH may be empty

Also adds WFE_IO_DIR env var for shared filesystem support with remote
daemons, and documents the remote daemon setup in lib.rs.
2026-03-29 16:56:59 +01:00
b0bf71aa61 feat(wfe-rustlang): add external tool auto-install and cargo-doc-mdx
External cargo tools (audit, deny, nextest, llvm-cov) auto-install
via cargo install if not found on the system. For llvm-cov, the
llvm-tools-preview rustup component is also installed automatically.

New cargo-doc-mdx step type generates MDX documentation from rustdoc
JSON output. Runs cargo +nightly rustdoc --output-format json, then
transforms the JSON into MDX files with frontmatter, type signatures,
and doc comments grouped by module. Uses the official rustdoc-types
crate for deserialization.
2026-03-29 16:56:21 +01:00
0cb26df68b feat(wfe-rustlang): add Rust toolchain step executors
New crate providing cargo and rustup step types for WFE workflows:

Cargo steps: build, test, check, clippy, fmt, doc, publish
Rustup steps: rust-install, rustup-toolchain, rustup-component, rustup-target

Shared CargoConfig base with toolchain, package, features, release,
target, profile, extra_args, env, working_dir, and timeout support.
Toolchain override via rustup run for any cargo command.
2026-03-29 16:56:07 +01:00
a7c2eb1d9b chore: add sunbeam registry annotations for crate publishing 2026-03-27 00:35:42 +00:00
496a192198 chore: bump version to 1.4.0 v1.4.0 2026-03-26 23:52:50 +00:00
d9e2c485f4 fix: pipeline coverage step produces valid JSON, deno reads it with readFile() 2026-03-26 23:37:34 +00:00
ed9c97ca32 fix: add host_context field to container executor test contexts 2026-03-26 23:37:24 +00:00
31a46ecbbd feat(wfe-yaml): add readFile() op to deno runtime with permission checking 2026-03-26 23:29:11 +00:00
d3426e5d82 feat(wfe-yaml): auto-convert ##wfe[output] values to typed JSON (bool, number) 2026-03-26 23:28:10 +00:00
ed38caecec fix(wfe-core): resolve .outputs. paths flat and pass empty object to child workflows 2026-03-26 23:18:48 +00:00
f0cc531ada docs: update README with condition system and task file include documentation 2026-03-26 17:26:11 +00:00
b1a1098fbc test(wfe-yaml): add condition schema, compiler, validation, and include tests 2026-03-26 17:25:26 +00:00
04c52c8158 feat(wfe-yaml): add task file includes with cycle detection and config override 2026-03-26 17:22:02 +00:00
1f14c9ac9a feat(wfe-yaml): add condition field path validation, type checking, and unused output detection 2026-03-26 17:21:50 +00:00
6c11473999 feat(wfe-yaml): compile YAML conditions into StepCondition with all operators 2026-03-26 17:21:28 +00:00
ced1916def feat(wfe-yaml): add YamlCondition types with combinator and comparison deserialization 2026-03-26 17:21:20 +00:00