# Installation Guide (`INSTALL.md`) Detailed installation, environment configuration, container build, and operator setup instructions for `trymemcp`. ## Prerequisites - **Python**: `3.11` or newer - **Docker**: `24.0+` and Docker Compose v2 (for containerized execution) - **Helm**: `v3.14+` (optional, for Kubernetes deployments) ## 1. Virtual Environment Installation ```bash # Create virtual environment python3 -m venv venv # Upgrade pip and install package + dev dependencies venv/bin/pip install --upgrade pip venv/bin/pip install -e ".[dev]" ``` ## 2. Environment Variables Create an optional `.env` file or export variables directly in your shell: ```bash export MCP_HOST="0.0.0.0" export MCP_PORT="8000" export MCP_PATH="/mcp" export TRYME_BASE_URL="https://tryme.tpk.pw" export TRYME_TIMEOUT_SECONDS="30" # Optional server-wide default credentials export TRYME_API_KEY="" export TRYME_BEARER_TOKEN="" export TRYME_SESSION_COOKIE="" ``` > **Database Note**: `trymemcp` is a stateless MCP HTTP proxy/adapter over the upstream TryMe REST API (`https://tryme.tpk.pw`) and does not require a local database or Alembic migrations. ## 3. Running the Service ```bash # Direct Python execution (serves HTTP on 0.0.0.0:8000) venv/bin/python -m app.main # Run test suite venv/bin/pytest ``` ## 4. Docker & Docker Compose Installation ```bash # Build production multi-stage image docker build -t trymemcp:0.1 . # Run container on port 8000 docker run -p 8000:8000 trymemcp:0.1 # Or run via Docker Compose docker compose up --build ``` ## 5. Gitea CI/CD Secrets Setup Before pushing to `main`, operators must configure these secrets in the Gitea repository settings for [`.gitea/workflows/cicd.yaml`](./.gitea/workflows/cicd.yaml): - `CR_USER` / `CR_PAT`: Harbor container registry & OCI Helm chart repo (`harbor.freshbrewed.science`) credentials. - `DHUSER` / `DHPAT`: DockerHub registry credentials.