Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 27 additions & 12 deletions .container/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,22 +1,37 @@
FROM python:3.10-bookworm

# Install uv and common tools
RUN apt-get update && apt-get install -y curl git && \
pip install uv && \
rm -rf /var/lib/apt/lists/*
# Install system dependencies and Poetry
RUN apt-get update && apt-get install -y \
curl \
git \
build-essential \
&& rm -rf /var/lib/apt/lists/* && \
pip install poetry

# Set workdir
WORKDIR /app/oasis

# Copy code
COPY . .
# Copy Poetry files and README first for better caching
COPY pyproject.toml README.md ./

# Set up venv + install dev deps
RUN uv venv .venv --python=3.10 && \
. .venv/bin/activate && \
uv pip install -e ".[dev]" && \
pip install pre-commit mypy && \
pre-commit install
# Configure Poetry
RUN poetry config virtualenvs.create false

# Generate new lock file and install dependencies without the root package
RUN poetry lock && poetry install --with dev --no-root --no-interaction --no-ansi

# Copy remaining source code
COPY oasis/ ./oasis/

# Install the root package now that source is available
RUN poetry install --only-root --no-interaction --no-ansi

# Install pre-commit hooks (development)
RUN poetry run pre-commit install || true

# Set environment variables
ENV PYTHONPATH=/app/oasis
ENV PYTHONUNBUFFERED=1

# Keep container alive for development
CMD ["tail", "-f", "/dev/null"]
8 changes: 5 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,21 @@ python = ">=3.10.0,<3.12"
pandas = "2.2.2"
igraph = "0.11.6"
cairocffi = "1.7.1"
pytest = "8.2.0"
pytest-asyncio = "0.23.6"
pillow = "10.3.0"
unstructured = "0.13.7"
sentence-transformers = "3.0.0"
pre-commit = "3.7.1"
prance = "23.6.21.0"
openapi-spec-validator = "0.7.1"
slack_sdk = "3.31.0"
neo4j = "5.23.0"
camel-ai = "0.2.70"
requests_oauthlib = "2.0.0"

[tool.poetry.group.dev.dependencies]
pytest = "8.2.0"
pytest-asyncio = "0.23.6"
pre-commit = "3.7.1"

[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
Loading