Skip to content

Commit 8ff3b48

Browse files
author
marwan37
committed
generate updated Dockerfile.sandbox files
1 parent ec8f24e commit 8ff3b48

File tree

2 files changed

+25
-19
lines changed

2 files changed

+25
-19
lines changed

omni-reader/Dockerfile.sandbox

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,20 @@
11
# Sandbox base image
22
FROM zenmldocker/zenml-sandbox:latest
33

4+
# Install uv from official distroless image
5+
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
6+
7+
# Set uv environment variables for optimization
8+
ENV UV_SYSTEM_PYTHON=1
9+
ENV UV_COMPILE_BYTECODE=1
10+
411
# Project metadata
512
LABEL project_name="omni-reader"
613
LABEL project_version="0.1.0"
714

8-
# Install dependencies
9-
RUN pip install uv
10-
RUN uv pip install --system \
15+
# Install dependencies with uv and cache optimization
16+
RUN --mount=type=cache,target=/root/.cache/uv \
17+
uv pip install --system \
1118
"instructor" \
1219
"jiwer" \
1320
"jiter" \
@@ -37,7 +44,6 @@ RUN git clone --depth 1 https://github.com/zenml-io/zenml-projects.git /tmp/zenm
3744
RUN mkdir -p /workspace/.vscode && \
3845
printf '{\n "workbench.colorTheme": "Default Dark Modern"\n}' > /workspace/.vscode/settings.json
3946

40-
# Create a template .env file for API keys
41-
RUN echo "MISTRAL_API_KEY=YOUR_MISTRAL_API_KEY" >> /workspace/.env
42-
RUN echo "OLLAMA_HOST=YOUR_OLLAMA_HOST" >> /workspace/.env
43-
RUN echo "OPENAI_API_KEY=YOUR_OPENAI_API_KEY" >> /workspace/.env
47+
# Copy .env.example
48+
COPY .env.example /workspace/.env
49+
ENV POLARS_SKIP_CPU_CHECK=1

oncoclear/Dockerfile.sandbox

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,20 @@
11
# Sandbox base image
22
FROM zenmldocker/zenml-sandbox:latest
33

4+
# Install uv from official distroless image
5+
COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/
6+
7+
# Set uv environment variables for optimization
8+
ENV UV_SYSTEM_PYTHON=1
9+
ENV UV_COMPILE_BYTECODE=1
10+
411
# Project metadata
512
LABEL project_name="oncoclear"
613
LABEL project_version="0.1.0"
714

8-
# Install dependencies
9-
RUN pip install uv
10-
RUN uv pip install --system \
15+
# Install dependencies with uv and cache optimization
16+
RUN --mount=type=cache,target=/root/.cache/uv \
17+
uv pip install --system \
1118
"zenml[server]>=0.50.0" \
1219
"notebook" \
1320
"scikit-learn" \
@@ -22,15 +29,8 @@ RUN git clone --depth 1 https://github.com/zenml-io/zenml-projects.git /tmp/zenm
2229
cp -r /tmp/zenml-projects/oncoclear/* /workspace/ && \
2330
rm -rf /tmp/zenml-projects
2431

25-
# Create a template .env file for API keys
26-
RUN echo "ZENML_PROJECT_SECRET_NAME=YOUR_ZENML_PROJECT_SECRET_NAME" && \
27-
echo "ZENML_STORE_URL=YOUR_ZENML_STORE_URL" && \
28-
echo "ZENML_STORE_API_KEY=YOUR_ZENML_STORE_API_KEY" > .env
29-
30-
# Create a .vscode directory and settings.json file
32+
# VSCode settings
3133
RUN mkdir -p /workspace/.vscode && \
32-
echo '{\n'\
33-
' "workbench.colorTheme": "Default Dark Modern"\n'\
34-
'}' > /workspace/.vscode/settings.json
34+
printf '{\n "workbench.colorTheme": "Default Dark Modern"\n}' > /workspace/.vscode/settings.json
3535

3636

0 commit comments

Comments
 (0)