openai는 provider prefix이고, codex는 OpenAI agent turn을 Codex app-server로 실행하는 runtime이다. openai/gpt-*는 “OpenAI provider의 GPT 모델을 쓰겠다”는 model ref이고, 그 turn을 실제로 실행하는 runtime은 별도로 정해진다. “provider와 runtime이 분리되어 있다”는 말은 아무 provider나 아무 runtime에 꽂을 수 있다는 뜻이 아니다. model ref는 모델/인증/카탈로그의 canonical name이고, runtime은 그 turn을 실행할 수 있는 호환 executor다(OpenClaw는 runtime selection에서 model-scoped policy, provider-scoped policy, plugin runtime claim 순서로 고른다고 설명한다). Codex app-server runtime은 OpenAI/Codex 계열 agent turn 전용이다.openai/* 또는 openai-codex/* turn을 Codex app-server로 넘길 수 있지만, 이건 opt-in이다. 문서가 “This is opt-in only. Default Hermes behavior is unchanged unless you flip the flag. Hermes never auto-routes you onto this runtime.”라고 못 박고 있다.Codex profile이라고 불리는 Codex app-server 설정과 인증 등을 여러 폴더에 분리하려면 CODEX_HOME을 사용해야 한다.
설정의 기본 전역 위치는 ~/.codex/config.toml이다. 이때 CODEX_HOME을 명시하여 config file을 $CODEX_HOME/profile-name.config.toml 경로로 잡고 Codex profile-specific config file을 둘 수 있다.
Codex는 로그인 정보를 캐시하고, CLI와 IDE extension이 같은 cached login details를 공유한다. 로그인 정보의 기본 저장 위치는 OS credential store 이다. cli_auth_credentials_store를 keyring 또는 auto로 두면 OS credential store가 사용되지만 cli_auth_credentials_store = "file"을 쓰면 로그인 정보도 $CODEX_HOME/auth.json에 저장된다.
# $CODEX_HOME/config.toml
cli_auth_credentials_store = "file"
<aside> 💡
Codex credential store를 file이 아닌 keyring 또는 auto로 두면 OS credential store가 사용되므로, ~ 을 공유하는 같은 OS user 안에서 여러 계정을 사용하기 어려울 수 있다. OpenAI 문서상 file은 CODEX_HOME 아래 auth.json에 저장하고, keyring은 OS credential store에 저장하며, auto는 가능한 경우 OS credential store를 쓰고 아니면 auth.json으로 fallback한다고 언급한다.
</aside>
그럼 이제 이렇게 된다. 예를 들어:
# Hermes personal profile에서 Codex를 부를 때
CODEX_HOME="$HOME/.hermes/profiles/personal/codex" codex
# Hermes work profile에서 Codex를 부를 때
CODEX_HOME="$HOME/.hermes/profiles/work/codex" codex
이 경로에서는 CODEX_HOME이 아무 영향을 주지 않는다. CODEX_HOME에 저장되는 정보들은 Codex app-server 런타임에 영향을 주는 상태값인데, 애초에 Hermes native harness을 사용하면서 Codex app-server가 LLM runtime으로 개입하지 않기 때문이다.
Hermes native harness의 openai-codex 인증은 CODEX_HOME이 아닌 Hermes auth store, HERMES_HOME/auth.json에 저장된다. 따라서 Hermes profile별로 Hermes native harness가 사용하는 인증을 분리하려면 각 profile마다 HERMES_HOME을 지정한 상태에서 Hermes OAuth 로그인을 따로 수행해야 한다.
예를 들어 personal profile은 이렇게 로그인한다.
PROFILE_HOME="$HOME/.hermes/profiles/personal"
HERMES_HOME="$PROFILE_HOME" \
hermes auth add openai-codex --type oauth --label personal
work profile도 별도로 로그인한다.
PROFILE_HOME="$HOME/.hermes/profiles/work"
HERMES_HOME="$PROFILE_HOME" \
hermes auth add openai-codex --type oauth --label work
이렇게 하면 각 Hermes profile은 자기 자신의 auth.json을 사용한다. 로그인 상태는 profile별로 확인한다.