This repository was archived by the owner on Apr 14, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
47 lines (35 loc) · 1.38 KB
/
Dockerfile
File metadata and controls
47 lines (35 loc) · 1.38 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
46
47
# syntax=docker/dockerfile:1
# ---- Build stage ----
FROM rust:1.86-slim AS builder
RUN apt-get update && apt-get install -y --no-install-recommends \
pkg-config \
libssl-dev \
build-essential \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /build
COPY Cargo.toml Cargo.lock ./
COPY src/ src/
COPY benches/ benches/
RUN cargo build --release && strip target/release/ai-memory
# ---- Runtime stage ----
FROM debian:bookworm-slim
LABEL org.opencontainers.image.title="ai-memory" \
org.opencontainers.image.description="AI-agnostic persistent memory system — MCP server, HTTP API, and CLI" \
org.opencontainers.image.version="0.5.2" \
org.opencontainers.image.source="https://github.com/alphaonedev/ai-memory-mcp" \
org.opencontainers.image.licenses="Apache-2.0" \
org.opencontainers.image.vendor="AlphaOne LLC" \
io.modelcontextprotocol.server.name="io.github.alphaonedev/ai-memory"
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates \
&& rm -rf /var/lib/apt/lists/* \
&& groupadd --system aimem \
&& useradd --system --gid aimem --create-home aimem \
&& mkdir -p /data && chown aimem:aimem /data
COPY --from=builder /build/target/release/ai-memory /usr/local/bin/ai-memory
ENV AI_MEMORY_DB=/data/ai-memory.db
VOLUME /data
EXPOSE 9077
USER aimem
ENTRYPOINT ["ai-memory"]
CMD ["serve", "--host", "0.0.0.0"]