Skip to content

Packaging & Distribution

This guide covers how to package MCP Gateway for deployment in various environments, including building production containers and generating releases.


πŸ“¦ Production Container (Podman or Docker)

Build an OCI-compliant container image using:

make podman
podman build -t mcpgateway:latest -f Containerfile .

Or with Docker (if Podman is not available):

make docker
# or manually
docker build -t mcpgateway:latest -f Containerfile .

A lite image is also available for use in production, see Containerfile.lite


πŸ” Run with TLS (self-signed)

make podman-run-ssl

This uses self-signed certs from ./certs/ and runs HTTPS on port 4444.


πŸ›  Container Run (HTTP)

make podman-run

This runs the container without TLS on port 4444.


πŸ“ Versioning

MCP Gateway uses semantic versioning (MAJOR.MINOR.PATCH) and the version is defined in:

mcpgateway/__init__.py

You can bump the version manually or automate it via Git tags or CI/CD.


πŸ“ Release Artifacts

If you need to ship ZIPs, wheels, or a full binary:

python3 -m build

Outputs will be under dist/. You can then:

  • Push to PyPI (internal or public)
  • Upload to GitHub Releases
  • Package in a .deb, .rpm, etc.

πŸ“‚ What's in the Container?

A typical image includes:

  • Gunicorn running with mcpgateway.main:app
  • All code, static files, and compiled assets

You can override settings using environment variables at runtime.