#21305: Fix/proxy-ip-allow-list
docs
scripts
docker
size: S
Cluster:
Docker and Deployment Improvements
## Summary
Describe the problem and fix in 2–5 bullets:
- Problem:
- Why it matters:
- What changed:
- What did NOT change (scope boundary):
## Change Type (select all)
- [ ] Bug fix
- [ ] Feature
- [ ] Refactor
- [ ] Docs
- [ ] Security hardening
- [ ] Chore/infra
## Scope (select all touched areas)
- [ ] Gateway / orchestration
- [ ] Skills / tool execution
- [ ] Auth / tokens
- [ ] Memory / storage
- [ ] Integrations
- [ ] API / contracts
- [ ] UI / DX
- [ ] CI/CD / infra
## Linked Issue/PR
- Closes #
- Related #
## User-visible / Behavior Changes
List user-visible changes (including defaults/config).
If none, write `None`.
## Security Impact (required)
- New permissions/capabilities? (`Yes/No`)
- Secrets/tokens handling changed? (`Yes/No`)
- New/changed network calls? (`Yes/No`)
- Command/tool execution surface changed? (`Yes/No`)
- Data access scope changed? (`Yes/No`)
- If any `Yes`, explain risk + mitigation:
## Repro + Verification
### Environment
- OS:
- Runtime/container:
- Model/provider:
- Integration/channel (if any):
- Relevant config (redacted):
### Steps
1.
2.
3.
### Expected
-
### Actual
-
## Evidence
Attach at least one:
- [ ] Failing test/log before + passing after
- [ ] Trace/log snippets
- [ ] Screenshot/recording
- [ ] Perf numbers (if relevant)
## Human Verification (required)
What you personally verified (not just CI), and how:
- Verified scenarios:
- Edge cases checked:
- What you did **not** verify:
## Compatibility / Migration
- Backward compatible? (`Yes/No`)
- Config/env changes? (`Yes/No`)
- Migration needed? (`Yes/No`)
- If yes, exact upgrade steps:
## Failure Recovery (if this breaks)
- How to disable/revert this change quickly:
- Files/config to restore:
- Known bad symptoms reviewers should watch for:
## Risks and Mitigations
List only real risks for this PR. Add/remove entries as needed. If none, write `None`.
- Risk:
- Mitigation:
<!-- greptile_comment -->
<h3>Greptile Summary</h3>
Adds Docker/EasyRunner deployment support with dynamic proxy IP resolution and auto-configuration via entrypoint script. Major changes include new `docker-entrypoint.sh` that resolves `OPENCLAW_TRUSTED_PROXY_HOST` to IP and updates config, comprehensive EasyRunner deployment docs, and Dockerfile updates for proper permissions.
**Key Issues Found:**
- CIDR notation in fallback `trustedProxies` config won't work - `isTrustedProxyAddress` (`src/gateway/net.ts:51-55`) only does exact IP matching, not CIDR range matching
- Hardcoded gateway token committed in `.easyrunner/docker-compose-app.yaml` (should use placeholder)
- Legacy `moltbot` naming used instead of `openclaw` in compose file
**Positive Changes:**
- Dynamic proxy IP resolution via `getent hosts` is a good approach for EasyRunner's container networking
- Proper fallback when resolution fails
- Good security practices (non-root user, proper permissions on extensions/docs dirs)
<h3>Confidence Score: 2/5</h3>
- Not safe to merge - contains a critical bug where CIDR notation won't work
- Score reflects a critical logical error: the fallback `trustedProxies` config uses CIDR notation (`10.0.0.0/8`, etc.) but the implementation only supports exact IP matching. This means the proxy IP allow-list won't work as intended when `OPENCLAW_TRUSTED_PROXY_HOST` is not set, potentially breaking reverse proxy setups. Also includes hardcoded secrets and naming inconsistencies.
- `scripts/docker-entrypoint.sh` needs CIDR notation removed or CIDR support added to `src/gateway/net.ts`. `.easyrunner/docker-compose-app.yaml` needs placeholder token and naming fixes.
<sub>Last reviewed commit: 1b13eb1</sub>
<!-- greptile_other_comments_section -->
<sub>(2/5) Greptile learns from your feedback when you react with thumbs up/down!</sub>
<!-- /greptile_comment -->
Most Similar PRs
#9190: feat(docker): Add autonomous container self-restart and runtime pac...
by alexdredmon · 2026-02-05
81.6%
#7133: feat: Automated Docker setup with environment-based configuration
by synetalsolutions · 2026-02-02
81.4%
#9999: Docker: fix token mismatch and add dev setup workflow
by benclarkeio · 2026-02-06
81.3%
#8050: fix: docker hardening
by christopherbarnett96 · 2026-02-03
80.5%
#11915: Docs: Docker + reverse proxy deployment notes and pairing pitfalls
by walshd1 · 2026-02-08
80.4%
#12504: fix: allow docker cli container to connect to gateway
by bvanderdrift · 2026-02-09
79.6%
#8478: Security: remove --allow-unconfigured from default Dockerfile CMD
by uttej-badwane · 2026-02-04
79.4%
#6638: fix: make Dockerfile work on container platforms (Render, Railway, ...
by kaizen403 · 2026-02-01
78.9%
#17506: Fix Entrypoint in docker-compose
by NeilSCGH · 2026-02-15
78.8%
#15466: Vps setup merge
by tsekula · 2026-02-13
78.7%