Skip to content

Commit

Permalink
Fixing docker image building issues. (#612)
Browse files Browse the repository at this point in the history
Authored-by: Milo Hyben <[email protected]>
  • Loading branch information
vivbak authored Nov 15, 2023
1 parent 6d01ce6 commit d96115a
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions deploy/api/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
FROM debian:buster-slim
FROM python:3.11

ARG SM_ENVIRONMENT

ENV MAMBA_ROOT_PREFIX /root/micromamba
ENV PATH $MAMBA_ROOT_PREFIX/bin:$PATH
ENV PORT 8000
ENV SM_ENVIRONMENT ${SM_ENVIRONMENT}
# Allow statements and log messages to immediately appear in the Knative logs.
Expand All @@ -14,15 +12,7 @@ EXPOSE $PORT
WORKDIR /app/sample_metadata/
COPY requirements.txt requirements.txt

RUN apt-get update && \
apt-get install -y wget bash bzip2 zip build-essential && \
rm -r /var/lib/apt/lists/* /var/cache/apt/* && \
wget -qO- https://api.anaconda.org/download/conda-forge/micromamba/0.8.2/linux-64/micromamba-0.8.2-he9b6cbd_0.tar.bz2 | tar -xvj -C /usr/local bin/micromamba && \
mkdir $MAMBA_ROOT_PREFIX && \
micromamba install -y --prefix $MAMBA_ROOT_PREFIX -c conda-forge \
python=3.10 pip && \
pip install -r requirements.txt && \
rm -r /root/micromamba/pkgs
RUN pip install --no-cache-dir -r requirements.txt

COPY api api
COPY db db/
Expand Down

0 comments on commit d96115a

Please sign in to comment.