Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +8 -6
Dockerfile
CHANGED
|
@@ -5,22 +5,20 @@ WORKDIR /app
|
|
| 5 |
# Install dependencies
|
| 6 |
RUN apk add --no-cache python3 py3-pip git py3-uv nodejs npm
|
| 7 |
|
|
|
|
|
|
|
|
|
|
| 8 |
# Clone One-MCP
|
| 9 |
RUN git clone https://github.com/One-MCP/multi-mcp.git .
|
| 10 |
RUN uv venv && . .venv/bin/activate && uv pip install -r requirements.txt
|
| 11 |
|
| 12 |
-
# Copy requirements
|
| 13 |
COPY tools/requirements/ /tmp/requirements/
|
| 14 |
-
|
| 15 |
-
# Create shared venv for simple tools
|
| 16 |
RUN python3 -m venv /app/venvs/shared
|
| 17 |
RUN /app/venvs/shared/bin/pip install -r /tmp/requirements/shared.txt
|
| 18 |
-
|
| 19 |
-
# Create individual venvs for complex tools (skip shared.txt)
|
| 20 |
RUN for req in /tmp/requirements/*.txt; do \
|
| 21 |
name=$(basename "$req" .txt); \
|
| 22 |
if [ "$name" != "shared" ]; then \
|
| 23 |
-
echo "Creating venv for $name"; \
|
| 24 |
python3 -m venv "/app/venvs/$name"; \
|
| 25 |
"/app/venvs/$name/bin/pip" install -r "$req"; \
|
| 26 |
fi; \
|
|
@@ -36,6 +34,10 @@ ENV UV_CACHE_DIR=/app/.uv-cache
|
|
| 36 |
RUN mkdir /app/.npm-cache && chmod -R 777 /app/.npm-cache
|
| 37 |
ENV npm_config_cache=/app/.npm-cache
|
| 38 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 39 |
# One-MCP settings
|
| 40 |
ENV CONFIG=/app/mcp.json
|
| 41 |
ENV TRANSPORT=sse
|
|
|
|
| 5 |
# Install dependencies
|
| 6 |
RUN apk add --no-cache python3 py3-pip git py3-uv nodejs npm
|
| 7 |
|
| 8 |
+
# Create writable directory for mcp-remote auth configs
|
| 9 |
+
RUN mkdir -p /app/.mcp-auth && chmod 777 /app/.mcp-auth
|
| 10 |
+
|
| 11 |
# Clone One-MCP
|
| 12 |
RUN git clone https://github.com/One-MCP/multi-mcp.git .
|
| 13 |
RUN uv venv && . .venv/bin/activate && uv pip install -r requirements.txt
|
| 14 |
|
| 15 |
+
# Copy requirements and create venvs
|
| 16 |
COPY tools/requirements/ /tmp/requirements/
|
|
|
|
|
|
|
| 17 |
RUN python3 -m venv /app/venvs/shared
|
| 18 |
RUN /app/venvs/shared/bin/pip install -r /tmp/requirements/shared.txt
|
|
|
|
|
|
|
| 19 |
RUN for req in /tmp/requirements/*.txt; do \
|
| 20 |
name=$(basename "$req" .txt); \
|
| 21 |
if [ "$name" != "shared" ]; then \
|
|
|
|
| 22 |
python3 -m venv "/app/venvs/$name"; \
|
| 23 |
"/app/venvs/$name/bin/pip" install -r "$req"; \
|
| 24 |
fi; \
|
|
|
|
| 34 |
RUN mkdir /app/.npm-cache && chmod -R 777 /app/.npm-cache
|
| 35 |
ENV npm_config_cache=/app/.npm-cache
|
| 36 |
|
| 37 |
+
# Set home directory for mcp-remote configs
|
| 38 |
+
ENV HOME=/app
|
| 39 |
+
ENV MCP_CONFIG_DIR=/app/.mcp-auth
|
| 40 |
+
|
| 41 |
# One-MCP settings
|
| 42 |
ENV CONFIG=/app/mcp.json
|
| 43 |
ENV TRANSPORT=sse
|