- Create custom Dockerfile to properly build and deploy MCP server - Simplify railway.json to rely on Dockerfile configuration - Ensure mcp_server directory and dependencies are correctly handled - Set proper PYTHONPATH and port configuration for Railway 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
24 lines
No EOL
478 B
Docker
24 lines
No EOL
478 B
Docker
FROM python:3.10-slim
|
|
|
|
# Set working directory
|
|
WORKDIR /app
|
|
|
|
# Install uv for dependency management
|
|
RUN pip install uv
|
|
|
|
# Copy the entire project
|
|
COPY . .
|
|
|
|
# Install dependencies for the MCP server
|
|
WORKDIR /app/mcp_server
|
|
RUN uv sync
|
|
|
|
# Set environment variables
|
|
ENV PORT=8080
|
|
ENV PYTHONPATH=/app:/app/mcp_server
|
|
|
|
# Expose port for Railway
|
|
EXPOSE 8080
|
|
|
|
# Run the MCP server
|
|
CMD ["uv", "run", "graphiti_mcp_server.py", "--transport", "sse", "--host", "0.0.0.0", "--port", "8080"] |