-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathDockerfile
More file actions
31 lines (24 loc) · 902 Bytes
/
Copy pathDockerfile
File metadata and controls
31 lines (24 loc) · 902 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Start from a base Python image
FROM python:3.12-slim
# For debugging purposes, install curl
RUN apt update && apt install -y \
curl \
&& rm -rf /var/lib/apt/lists/*
# Set the working directory
WORKDIR /app
# Copy the requirements file first to leverage Docker cache
COPY requirements.txt /app/requirements.txt
RUN pip install --no-cache-dir -r requirements.txt
# Copy the rest of the application code
# This includes the 'semantic_scholar' package and 'run.py'
COPY . /app
# Alternatively, be more specific:
# COPY semantic_scholar /app/semantic_scholar
# COPY run.py /app/run.py
# Expose the port that the MCP server will run on
EXPOSE 8000
# Set the environment variable for the API key (placeholder)
# Glama or the user should provide the actual key at runtime
ENV SEMANTIC_SCHOLAR_API_KEY=""
# Command to run the server using the refactored entry point
CMD ["python", "run.py"]