-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
45 lines (32 loc) · 1.23 KB
/
Dockerfile
File metadata and controls
45 lines (32 loc) · 1.23 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
FROM ubuntu:22.04 AS builder
RUN apt update && \
apt install -y build-essential cmake git libssl-dev && \
apt clean && \
rm -rf /var/lib/apt/lists/*
WORKDIR /app
#RUN rm -rf /app/build
COPY . .
RUN mkdir -p build && \
cd build && \
cmake -DCMAKE_BUILD_TYPE=Release -DCPACK_INCLUDE_LIBS=OFF .. && \
make -j$(nproc) && \
strip bin/mcp-server++
# -----------------------------------------------------------------------------------#
FROM debian:12-slim
RUN echo 'deb https://mirrors.ustc.edu.cn/debian bookworm main' > /etc/apt/sources.list && \
echo 'deb https://mirrors.ustc.edu.cn/debian bookworm-updates main' >> /etc/apt/sources.list && \
echo 'deb https://mirrors.ustc.edu.cn/debian-security bookworm-security main' >> /etc/apt/sources.list
RUN apt-get update && \
apt-get install -y --no-install-recommends ca-certificates && \
rm -rf /var/lib/apt/lists/*
RUN apt-get update && \
apt-get install -y --no-install-recommends \
libssl3 \
ca-certificates && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
COPY --from=builder /app/build/bin/mcp-server++ /mcp-server++
COPY config.ini.example /config.ini
RUN mkdir -p /logs /plugins
EXPOSE 6666 6667
CMD ["/mcp-server++"]