-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathdockerfile
More file actions
33 lines (23 loc) · 767 Bytes
/
dockerfile
File metadata and controls
33 lines (23 loc) · 767 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
FROM nvcr.io/nvidia/cuda:11.2.1-cudnn8-runtime-ubuntu18.04
LABEL maintainer "BMW InnovationLab"
ARG DEBIAN_FRONTEND=noninteractive
COPY src/main /main
RUN apt-get update && apt-get upgrade -y && apt-get install -y \
locales \
software-properties-common \
python3-pip \
python3-dev \
pkg-config \
ffmpeg
# copy package requirements
COPY docker/GPU/requirements.txt .
# install packages
RUN pip3 install --upgrade pip
RUN pip3 install -r requirements.txt
# configure uvicorn
RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
dpkg-reconfigure --frontend=noninteractive locales && \
update-locale LANG=en_US.UTF-8
ENV LANG en_US.UTF-8
WORKDIR /main
CMD ["uvicorn", "start:app", "--host", "0.0.0.0", "--port", "4343"]