Skip to content
Merged
80 changes: 80 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: CI

on:
push:
branches: [main]
pull_request:

permissions:
contents: read

jobs:
lint:
name: ruff + mypy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install package with dev dependencies
run: |
uv venv
uv pip install -e ".[dev]"

- name: ruff check
run: uv run ruff check src tests

- name: mypy
run: uv run mypy src/mcp_reverse_proxy

test:
name: pytest (Python ${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install package with dev dependencies
run: |
uv venv
uv pip install -e ".[dev]"

- name: Run tests
run: uv run pytest tests/ -q

build:
name: Build wheel + sdist
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Build distributions
run: uv build

- name: Upload distributions
uses: actions/upload-artifact@v4
with:
name: dist
path: dist/
retention-days: 7
45 changes: 45 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Release

on:
push:
tags:
- "v*"

permissions:
contents: read

jobs:
build:
name: Build distributions
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: Build distributions
run: uv build

- name: Upload distributions
uses: actions/upload-artifact@v4
with:
name: dist
path: dist/

publish:
name: Publish to PyPI (trusted publishing)
needs: build
runs-on: ubuntu-latest
environment: pypi
permissions:
id-token: write # OIDC token for PyPI trusted publishing (no API token)
steps:
- name: Download distributions
uses: actions/download-artifact@v4
with:
name: dist
path: dist/

- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ A gateway-side integration package, `mcp-reverse-proxy-contextforge`, is planned
## Documentation

- [docs/README.md](docs/README.md): architecture, transport abstraction, and health-check strategy
- [docs/USER_README.md](docs/USER_README.md): user guide with installation, TLS configuration, and troubleshooting
- [USER_README.md](USER_README.md): user guide with installation, TLS configuration, and troubleshooting

## Development

Expand Down
Loading
Loading