core-agent-ide/codex-rs/cli/src
Fouad Matin a5b7675e42
add(core): managed config (#3868)
## Summary

- Factor `load_config_as_toml` into `core::config_loader` so config
loading is reusable across callers.
- Layer `~/.codex/config.toml`, optional `~/.codex/managed_config.toml`,
and macOS managed preferences (base64) with recursive table merging and
scoped threads per source.

## Config Flow

```
Managed prefs (macOS profile: com.openai.codex/config_toml_base64)
                               ▲
                               │
~/.codex/managed_config.toml   │  (optional file-based override)
                               ▲
                               │
                ~/.codex/config.toml (user-defined settings)
```

- The loader searches under the resolved `CODEX_HOME` directory
(defaults to `~/.codex`).
- Managed configs let administrators ship fleet-wide overrides via
device profiles which is useful for enforcing certain settings like
sandbox or approval defaults.
- For nested hash tables: overlays merge recursively. Child tables are
merged key-by-key, while scalar or array values replace the prior layer
entirely. This lets admins add or tweak individual fields without
clobbering unrelated user settings.
2025-10-03 13:02:26 -07:00
..
debug_sandbox.rs add(core): managed config (#3868) 2025-10-03 13:02:26 -07:00
exit_status.rs feat: experimental env var: CODEX_SANDBOX_NETWORK_DISABLED (#879) 2025-05-09 18:29:34 -07:00
lib.rs Delete codex proto (#4520) 2025-09-30 22:33:28 +00:00
login.rs add(core): managed config (#3868) 2025-10-03 13:02:26 -07:00
main.rs fix: replace --api-key with --with-api-key in codex login (#4646) 2025-10-03 06:17:31 +00:00
mcp_cmd.rs add(core): managed config (#3868) 2025-10-03 13:02:26 -07:00