Skip to content

Commit e2433a5

Browse files
committed
Fixed Dockerfile.dev
1 parent be116d6 commit e2433a5

File tree

1 file changed

+22
-3
lines changed

1 file changed

+22
-3
lines changed

Diff for: backend/Dockerfile.dev

+22-3
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,30 @@ FROM pennlabs/django-base:b269ea1613686b1ac6370154debbb741b012de1a-3.11
22

33
LABEL maintainer="Penn Labs"
44

5+
# Install dependencies
6+
RUN apt-get update \
7+
&& apt-get install --no-install-recommends -y wget \
8+
&& apt-get clean \
9+
&& rm -rf /var/lib/apt/lists/*
10+
11+
# Install uv
12+
# Download the latest installer
13+
ADD https://astral.sh/uv/0.6.0/install.sh /uv-installer.sh
14+
15+
RUN echo "5464b06094b6363861b99cd60a010892e52fc2a7503b7594419828e74afecfe6 /uv-installer.sh" | sha256sum -c
16+
17+
# Run the installer then remove it
18+
RUN sh /uv-installer.sh && rm /uv-installer.sh
19+
20+
# Ensure the installed binary is on the `PATH`
21+
ENV PATH="/root/.local/bin/:$PATH"
22+
523
# Copy project dependencies
6-
COPY Pipfile* /app/
24+
COPY pyproject.toml /app/
25+
COPY uv.lock /app/
726

827
# Install project dependencies
9-
RUN pipenv install --system
28+
RUN cd /app/ && uv sync
1029

1130
# Copy project files
1231
COPY . /app/
@@ -15,4 +34,4 @@ ENV DJANGO_SETTINGS_MODULE Platform.settings.staging
1534
ENV SECRET_KEY 'temporary key just to build the docker image'
1635

1736
# Collect static files
18-
RUN python3 /app/manage.py collectstatic --noinput
37+
RUN uv run /app/manage.py collectstatic --noinput

0 commit comments

Comments
 (0)