Skip to content

Commit 7eb46ef

Browse files
authored
Merge pull request #348 from GREENRAT-K405/fix/optimize-python-dockerfile
Optimize Dockerfile for python environment
2 parents af68145 + bb996f1 commit 7eb46ef

1 file changed

Lines changed: 5 additions & 6 deletions

File tree

Dockerfile.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
FROM jupyter/base-notebook
1+
FROM python:3.10-slim
22

3-
USER root
4-
RUN apt-get update && apt-get install -y build-essential g++ libgl1-mesa-glx libx11-6
5-
COPY requirements.txt .
6-
RUN pip install -r requirements.txt
7-
COPY . /src
83
WORKDIR /src
4+
RUN apt-get update && apt-get install -y build-essential g++ libgl1-mesa-glx libx11-6 && rm -rf /var/lib/apt/lists/*
5+
COPY requirements.txt .
6+
RUN pip install --no-cache-dir -r requirements.txt
7+
COPY . .
98

0 commit comments

Comments
 (0)