Commit graph

21 commits

Author SHA1 Message Date
Chummy
57be369771 chore(docker): keep install list indentation unchanged 2026-02-18 15:14:05 +08:00
Cemal Y. Dalar
7f15627f8c fix(docker): restore benches/ copy after stub removal in builder stage
The dep-caching layer creates stub files (src/main.rs and
benches/agent_benchmarks.rs) to warm the cargo registry cache, then
removes them with `rm -rf src benches`. The subsequent real source copy
only restored `src/` — leaving `benches/` absent. Cargo's manifest
parser then failed to locate `benches/agent_benchmarks.rs` referenced
in Cargo.toml, aborting the release build with:

  error: failed to parse manifest at `/app/Cargo.toml`
  Caused by: can't find `agent_benchmarks` bench at
  `benches/agent_benchmarks.rs`

Fix: add `COPY benches/ benches/` alongside the `COPY src/ src/` step
so the real bench source is present for the incremental release build.
2026-02-18 15:14:05 +08:00
Alex Gorevski
da326b265d fix(container): address all container anti-patterns (4.1–4.4)
- Replace broad COPY . . with targeted COPY src/ and firmware/ to
  preserve Docker layer cache across non-build file changes (4.1)
- Inline permissions/config prep into builder stage, removing the
  extra busybox stage and its maintenance/security overhead (4.2)
- Strip heavy dev tools (vim, git, iputils-ping, openssl) from dev
  image, keeping only ca-certificates and curl (4.3)
- Replace expensive zeroclaw doctor healthcheck with lightweight
  zeroclaw status; increase interval from 30s to 60s (4.4)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-02-18 10:35:09 +08:00
Will Sarg
a973f31065
fix(docker): avoid double compile in smoke build (#686) 2026-02-17 17:00:23 -05:00
dependabot[bot]
48fdc1c113
chore(deps): bump rust in the docker-minor-patch group (#637)
Bumps the docker-minor-patch group with 1 update: rust.


Updates `rust` from 1.92-slim to 1.93-slim

---
updated-dependencies:
- dependency-name: rust
  dependency-version: 1.93-slim
  dependency-type: direct:production
  dependency-group: docker-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-17 16:48:48 -05:00
Will Sarg
95c3331bd5
fix(docker): provide dummy bench target in dependency-cache build (#682) 2026-02-17 16:43:36 -05:00
Will Sarg
30b9df761a
fix(gateway): persist pairing tokens and honor docker config (#630)
* fix(gateway): honor config bind settings and persist pairing

Resolve docker-compose startup and restart friction by:
- using config host/port defaults for gateway/daemon unless CLI flags are passed
- persisting paired token hashes to config.toml on successful /pair
- running container default command as 'zeroclaw gateway' (no hardcoded --host/--port overrides)
- updating compose image/docs to zeroclaw-labs namespace
- adding MODEL env fallback for default_model override and targeted regression tests

* chore(ci): sync lockfile and restore rustfmt parity

Update Cargo.lock to match Cargo.toml and format src/service/mod.rs so rust quality gates stop failing with unrelated baseline drift.
2026-02-17 15:05:56 -05:00
Will Sarg
98d06cba6b perf(docker): align builder toolchain with rust-toolchain and persist artifact 2026-02-17 09:23:01 -05:00
Will Sarg
b8bef379e2 fix(channels): reply via reply_target and improve local Docker cache reuse 2026-02-17 09:22:01 -05:00
fettpl
38f6339a83 ci: pin Docker base images to SHA256 digests
Pin all FROM images in Dockerfile and dev/ci/Dockerfile to their
current SHA256 manifest digests for reproducible builds.

- rust:1.93-slim-trixie → @sha256:9663b80a...
- busybox:latest → busybox:1.37@sha256:b3255e7d...
- debian:trixie-slim → @sha256:f6e2cfac...
- gcr.io/distroless/cc-debian13:nonroot → @sha256:84fcd3c2...
- rust:1.92-slim → @sha256:bf3368a9...

Closes #359

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 17:42:05 +01:00
Will Sarg
b61d33aa1c
feat(dev): add local dockerized ci workflow (#342) 2026-02-16 09:10:39 -05:00
Vernon Stinebaker
40c41cf3d2
feat(discord): add listen_to_bots config and fix model IDs across codebase (#280)
* fix(config): apply env overrides at runtime and fix Docker compose defaults

- Call apply_env_overrides() after Config::load_or_init() in main.rs so
  environment variables (API_KEY, PROVIDER, ZEROCLAW_GATEWAY_PORT, etc.)
  are actually applied at runtime, not just in tests
- Add ZEROCLAW_ALLOW_PUBLIC_BIND env var support for gateway bind policy
- Fix docker-compose.yml: correct volume path (/zeroclaw-data not /data),
  add ZEROCLAW_ALLOW_PUBLIC_BIND=true for container networking, make host
  port configurable via HOST_PORT env var
- Add docker-compose.override.yml to .gitignore for local dev overrides

* feat(discord): add listen_to_bots config and fix model IDs across codebase

Add listen_to_bots field to DiscordConfig so bot messages are processed
when explicitly enabled (defaults to false for backward compat). Remove
ZEROCLAW_MODEL from Dockerfile release stage so config.toml is the
source of truth for model selection. Fix all hardcoded model IDs from
the dated anthropic/claude-sonnet-4-20250514 to the valid OpenRouter
identifier anthropic/claude-sonnet-4.
2026-02-16 02:13:36 -05:00
Argenis
ebdcee3a5d
fix(build): remove OpenSSL dependency to prevent build failures
This fixes issue #271 where cargo build fails due to openssl-sys dependency
being pulled in even though the project uses rustls-tls for all TLS connections.

**Problem:**
- The Dockerfile installed `libssl-dev` in the builder stage
- This caused `openssl-sys` to be activated as a dependency
- Users without OpenSSL installed would get build failures:
  ```
  error: failed to run custom build command for openssl-sys v0.9.111
  Could not find directory of OpenSSL installation
  ```

**Solution:**
- Remove `libssl-dev` from Dockerfile build dependencies
- ZeroClaw uses `rustls-tls` exclusively for all TLS connections:
  - reqwest: `features = ["rustls-tls"]`
  - lettre: `features = ["rustls-tls"]`
  - tokio-tungstenite: `features = ["rustls-tls-webpki-roots"]`

**Benefits:**
- Smaller Docker images (no OpenSSL headers/libs needed)
- Faster builds (fewer dependencies to compile)
- Consistent builds regardless of system OpenSSL availability
- True pure-Rust TLS stack without C dependencies

**Affected platforms:**
- Users without OpenSSL dev packages can now build directly
- Docker builds are more portable and reproducible
- Binary distributions don't depend on system OpenSSL version

All tests pass.

Related to #271

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 01:58:40 -05:00
Gunnar Andersson
e98d1c2825 Squashme: Builder also on trixie
I noticed it was "fixed" already by holding back the builder.
Well, this is another alternative

(Squash this)
2026-02-16 01:47:18 +01:00
Gunnar Andersson
0104e46e60 Dockerfile: Update runtime images to debian 13
Dockerfile builder image 1.93-slim is (now?) based on debian trixie (13)

The production runtime image was created based on debian-12 which did
not have the version of libc that zeroclaw was built against and that
caused this error:

[zeroclaw] | zeroclaw: /lib/x86_64-linux-gnu/libc.so.6: version
`GLIBC_2.39' not found (required by zeroclaw)

Upgraded runtime image to debian 13 to solve the issue
2026-02-16 01:17:58 +01:00
Chummy
c80b118963
fix(docker): pin builder to bookworm to avoid glibc runtime mismatch
* fix(docker): pin builder to bookworm for glibc compatibility

* ci: skip rust lint on non-Rust PRs and allow 0BSD

* ci: pin actionlint action to existing release tag

* ci: make docs-only matcher shellcheck-clean

---------

Co-authored-by: chumyin <chumyin@users.noreply.github.com>
2026-02-15 15:03:29 -05:00
Argenis
20f857a55a
feat(dev): add containerized development environment
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 11:10:45 -05:00
Argenis
ced4d70814
feat(channels): wire up email channel (IMAP/SMTP) into config and registration
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 10:58:30 -05:00
argenis de la rosa
554f6e9ea5 feat: add browser automation tool using Vercel agent-browser
- Add src/tools/browser.rs with BrowserTool implementation
- Wraps agent-browser CLI for AI-optimized web browsing
- Supports: open, snapshot, click, fill, type, screenshot, wait, etc.
- Uses refs (@e1, @e2) from accessibility snapshots for precise element selection
- JSON output mode for LLM integration
- Security: allowlist-only domains, blocks private/local hosts
- Add session_name to BrowserConfig for persistent sessions
- Register BrowserTool in tools/mod.rs alongside BrowserOpenTool

All tests pass.
2026-02-14 15:46:36 -05:00
argenis de la rosa
76074cb789 fix: run Docker container as non-root user (closes #34)
- Switch to gcr.io/distroless/cc-debian12:nonroot
- Add explicit USER 65534:65534 directive
- Add Docker security CI job verifying non-root UID, :nonroot base, and USER directive
- Document CIS Docker Benchmark compliance in SECURITY.md
- Add tests and edge cases for container security
2026-02-14 13:16:33 -05:00
argenis de la rosa
05cb353f7f feat: initial release — ZeroClaw v0.1.0
- 22 AI providers (OpenRouter, Anthropic, OpenAI, Mistral, etc.)
- 7 channels (CLI, Telegram, Discord, Slack, iMessage, Matrix, Webhook)
- 5-step onboarding wizard with Project Context personalization
- OpenClaw-aligned system prompt (SOUL.md, IDENTITY.md, USER.md, AGENTS.md, etc.)
- SQLite memory backend with auto-save
- Skills system with on-demand loading
- Security: autonomy levels, command allowlists, cost limits
- 532 tests passing, 0 clippy warnings
2026-02-13 12:19:14 -05:00