-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathDockerfile
More file actions
37 lines (27 loc) · 964 Bytes
/
Dockerfile
File metadata and controls
37 lines (27 loc) · 964 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
32
33
34
35
36
37
FROM python:3.13-slim
LABEL Title="Okta MCP Server" \
Description="Model Context Protocol server for Okta API integration" \
Authors="Okta" \
Licenses="Apache-2.0" \
Version="1.0.0" \
Maintainer="Okta"
# Install uv
COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv
WORKDIR /app
# Copy dependency files first (for better caching)
COPY pyproject.toml uv.lock ./
COPY src ./src
# Copy README.md if it exists (needed by some builds)
COPY README.md ./
RUN uv sync --no-dev
# Create non-root user for security
RUN useradd --create-home --shell /bin/bash appuser \
&& chown -R appuser:appuser /app
USER appuser
# Set environment variables
ENV PATH="/app/.venv/bin:$PATH"
ENV PYTHONUNBUFFERED=1
# Use file-based keyring backend for Docker (no system keyring available)
ENV PYTHON_KEYRING_BACKEND=keyrings.alt.file.PlaintextKeyring
# Run the server using the console script entry point
ENTRYPOINT ["okta-mcp-server"]