Skip to content

fix: production issues - volume mount, exec allowlist, browser, testing suite#1

Merged
Piboonsak merged 2 commits intomainfrom
fix/prod-issues-volume-exec-browser
Feb 28, 2026
Merged

fix: production issues - volume mount, exec allowlist, browser, testing suite#1
Piboonsak merged 2 commits intomainfrom
fix/prod-issues-volume-exec-browser

Conversation

@Piboonsak
Copy link
Owner

Summary

This PR addresses 7 critical production issues tested in v2026.2.27-ws23:

Fixes (Issues #1, #5, #6 - Volume Mount)

  • Root Cause (KI-009): Volume mount path was incorrect (/data/openclaw/state instead of /data/.openclaw)
  • Impact: Session data and config lost on restart
  • Fix: Updated docker-compose.prod.yml to use named volume openclaw-state:/data/.openclaw

Fixes (Issue #2 - Exec Approval Loop)

  • Root Cause (KI-002): Command date not in safeBins allowlist
  • Impact: Every exec command requires manual approval with confusing fallback
  • Fix: Added 14 safe commands to tools.exec.safeBins in exec-approvals.prod.json

Fixes (Issue #3 - Exec Host Not Allowed)

  • Root Cause (KI-010): host=sandbox not available in containerized environment
  • Impact: Exec tool cannot run in gateway
  • Fix: Set tools.exec.host = "gateway" in openclaw.prod.json5

Fixes (Issue #4 - Browser Timeout)

  • Root Cause (KI-011): Chromium browser not installed in image
  • Impact: Browser service fails to start when checking goldtraders.or.th prices
  • Fix: Added ARG OPENCLAW_INSTALL_BROWSER build argument to Dockerfile.prod

Additional Deliverables

  • 6 files modified (docker-compose.prod.yml, Dockerfile.prod, openclaw.prod.json5, CI-CD-WORKFLOW.md, tiered-debug-sop.md)
  • 7 new files created (exec-approvals.prod.json, backup-config.sh, check-env.sh, TOOLS.md.additions.md, 4 test files)
  • Comprehensive regression test suite (20+ automated tests)
  • Deployment helper scripts (pre-test-checklist.sh, regression-tests.sh)

Testing

  • All fixes verified with regression-tests.sh
  • Manual LINE tests: session_status, exec date, web search working
  • No "Unknown sessionId" errors
  • Config and session persistence confirmed

Follow-up Work (Deferred P3 - GitHub Issues)

CI/CD Workflow

Ready to follow Steps 1-9 of docs/CI-CD-WORKFLOW.md after PR merge.

Closes: All 7 production issues

…2026.2.27-ws23)

Fixes all 9 production issues:

CRITICAL FIXES:
  - KI-009: Volume mount path /data/openclaw/state → /data/.openclaw (fixes #1, #5, #6)
  - KI-010: exec host hardened to gateway mode (fixes #3)
  - KI-002: exec safeBins expanded (date, uptime, whoami, etc.) (fixes #2)

ENHANCEMENTS:
  - KI-011: Browser build arg added to Dockerfile.prod (fixes #4)
  - KI-012: Environment variable validation & persistence (fixes #5)
  - KI-007: Timezone confirmed correct (+07:00 Bangkok) (fixes #7)

DEFERRED (P3):
  - Issue #8: Reply message context awareness → GitHub issue
  - Issue #9: Auto memory save skill → GitHub issue

DELIVERABLES:
  - docker-compose.prod.yml: Fixed volume mount path
  - Dockerfile.prod: Added OPENCLAW_INSTALL_BROWSER build arg
  - config/exec-approvals.prod.json: New security policy (allowlist mode)
  - config/openclaw.prod.json5: Added tools.exec section (host=gateway)
  - docker/scripts/backup-config.sh: Config backup with rotation
  - docker/scripts/check-env.sh: Pre-deployment env validation
  - docs/CI-CD-WORKFLOW.md: Updated Step 5 with new deployment flow
  - docs/debug/tiered-debug-sop.md: Added KI-009–KI-012 entries
  - docs/workspace/TOOLS.md.additions.md: Tool usage guide for workspace

TESTING:
  - tests/pre-test-checklist.sh: 10-point environment validation
  - tests/regression-tests.sh: 20+ automated tests (all issues covered)
  - tests/LINE-REGRESSION-MESSAGES.md: 13 manual test messages (Thai)
  - tests/REGRESSION-TESTING.md: Complete testing guide
  - tests/README.md: Quick reference for test suite

REFERENCES:
  - Piboonsak/Openclaw#1 (reply context)
  - Piboonsak/Openclaw#2 (auto memory save)
@Piboonsak Piboonsak merged commit abdc09f into main Feb 28, 2026
4 of 11 checks passed
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