Skip to Content
We are live but in Staging 🎉
MCP serverConnect Codex

Connect Codex

Who this is for: anyone using Codex Desktop or Codex CLI on their own computer who wants Codex to work directly with Dodil.

Recommended: use the local server. Codex can start dodil mcp on your computer over stdio. It is faster than a hosted connection, uses the Dodil login you already have, and does not require a separate API key or service account.

If you use ChatGPT in a web browser instead of Codex, use the hosted server in the ChatGPT guide. A web chat cannot start a program on your laptop.

Before you start

You need:

  • The dodil CLI installed on the same computer as Codex.
  • An active Dodil login. Check it with dodil auth status; if needed, run dodil auth login and complete the browser sign-in yourself.
  • Codex Desktop or Codex CLI.

Run these commands in a terminal first:

dodil --version dodil auth status

Both should succeed before you configure Codex. Do not run dodil mcp by itself in an interactive terminal and leave it open: Codex starts that process when it needs it.

Step 1 — Install or update the Dodil CLI

Install the dodil CLI. The installer registers Dodil with supported local agents, including Codex, when it can find them.

If Codex was closed while you installed Dodil, open a new Codex task after installation. MCP tools are discovered when a task starts, not continuously while it is open.

Step 2 — Add Dodil to Codex

Option A — Let the Dodil installer do it

This is the easiest path. Install the CLI, sign in with dodil auth login, and start a new Codex task. The installer normally adds the MCP server automatically.

Option B — Add it from Codex CLI

If the installer did not find Codex, add the server explicitly:

codex mcp add dodil -- dodil mcp

If dodil is not on your shell PATH, use its full path instead:

codex mcp add dodil -- /full/path/to/dodil mcp

The command tells Codex to launch dodil mcp whenever it needs Dodil tools. The connection uses stdio, which stays on your computer; it does not open a network port.

Option C — Add the configuration by hand

Open Codex’s configuration file at ~/.codex/config.toml and add:

[mcp_servers.dodil] command = "dodil" args = ["mcp"]

If your terminal does not find dodil without a full path, make that explicit:

[mcp_servers.dodil] command = "/full/path/to/dodil" args = ["mcp"]

Do not add the same server through both a command and a second hand-written entry. Keep one dodil entry so there is one predictable source of configuration.

Step 3 — Verify the connection

In a terminal, run:

codex mcp list

You should see a row similar to:

Name Command Args Status dodil dodil mcp enabled

Then start a new Codex Desktop task or a fresh Codex CLI session. Ask:

List my Dodil buckets.

Codex should discover Dodil’s typed tools automatically. It may ask for confirmation before a tool action; read the action before approving it.

Step 4 — Use it safely

Start with requests that only read data:

  • “List my Dodil buckets.”
  • “Show my Ignite apps and which ones are running.”
  • “What container images are in my Dodil registry?”
  • “Show the last 50 log lines for my Ignite app checkout.”

When you are comfortable, ask for a change such as: “Create a Dodil git repository called invoices-api.” Codex only has the permissions of the Dodil account you logged in with; it cannot bypass your organisation’s roles and policies.

Optional — Code mode

Normal mode exposes each Dodil command as a typed MCP tool. dodil mcp --enable-exec additionally exposes dodil_exec, which lets an agent run a Bash script with the CLI on PATH.

This is powerful but is arbitrary code execution. Leave it off unless you have a clear reason to let Codex run multi-command scripts. If you decide to enable it, change the args entry to:

args = ["mcp", "--enable-exec"]

Use it only with a local Codex setup you trust. It is deliberately unavailable on Dodil’s hosted remote MCP server.

Troubleshooting

SymptomWhat to do
codex mcp list does not show dodilRun codex mcp add dodil -- dodil mcp again, or check the ~/.codex/config.toml entry.
Codex says it cannot start dodilRun dodil --version. If it only works with a full path, use that full path in the Codex command or configuration.
Dodil appears in the list but not in this chatStart a new Codex task or CLI session. An already-running session does not gain newly configured tools.
Codex connects but gets an authorization errorRun dodil auth status; if it is expired, run dodil auth login and finish the browser login.
A command is missing or access is deniedThe MCP server mirrors the CLI and your Dodil roles. Check Roles and Policies.
You need a browser-only integrationUse the remote server through ChatGPT or Claude, not the local Codex setup.

Full list → Troubleshooting.