Skip to content

CLAUDE_CONFIG_DIR not handled #225

@jandroav

Description

@jandroav

The Docker MCP Gateway's Claude Code client configuration is not respecting the CLAUDE_CONFIG_DIR environment variable, always defaulting to ~/.claude.json regardless of whether users had set a custom configuration directory.

This breaks multi-profile workflows where users maintain separate Claude Code installations for different contexts (e.g., work vs. personal).

When users clicked the 'Connect' button in the MCP Toolkit UI with CLAUDE_CONFIG_DIR set, the gateway configures the wrong Claude Code installation, causing the MCP servers to be unavailable in the intended profile and potentially exposing them in an unintended one.

I created a PR updating the configuration path resolution to check $CLAUDE_CONFIG_DIR/.claude.json first before falling back to the default location.

PR: #224

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions