Skip to content

feat: support env vars in dev command#2529

Closed
HenryLee789 wants to merge 4 commits into
modelcontextprotocol:mainfrom
HenryLee789:codex/dev-env-vars
Closed

feat: support env vars in dev command#2529
HenryLee789 wants to merge 4 commits into
modelcontextprotocol:mainfrom
HenryLee789:codex/dev-env-vars

Conversation

@HenryLee789
Copy link
Copy Markdown

Summary

  • add --env-var/-v and --env-file/-f support to mcp dev
  • share environment collection logic with mcp install
  • document env var usage in the README and add CLI helper tests

Fixes #339

Testing

  • uv run pytest tests/cli/test_utils.py -q
  • uv run ruff check src/mcp/cli/cli.py tests/cli/test_utils.py

@maxisbey
Copy link
Copy Markdown
Contributor

Closing as a duplicate of #2506, which was opened first with the same feature. Thanks for the contribution.

AI Disclaimer

@maxisbey maxisbey closed this May 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[docs] How to run FastMCP with args or env vars?

2 participants