dia-gov commited on
Commit
26e80f3
·
verified ·
1 Parent(s): cd6f98e

Create Dockerfile

Browse files
Files changed (1) hide show
  1. platform/Dockerfile +15 -35
platform/Dockerfile CHANGED
@@ -1,37 +1,17 @@
1
- FROM python:3.11-slim-buster as prod
2
 
3
- RUN apt-get update && apt-get install -y \
4
- default-libmysqlclient-dev \
5
- gcc \
6
- pkg-config \
7
- openjdk-11-jdk \
8
- build-essential \
9
- && rm -rf /var/lib/apt/lists/*
10
-
11
- RUN pip install poetry==1.4.2
12
-
13
- # Configuring poetry
14
- RUN poetry config virtualenvs.create false
15
-
16
- # Copying requirements of a project
17
- COPY pyproject.toml /app/src/
18
- WORKDIR /app/src
19
-
20
- # Installing requirements
21
- RUN poetry install --only main
22
- # Removing gcc
23
- RUN apt-get purge -y \
24
- g++ \
25
- gcc \
26
- pkg-config \
27
- && rm -rf /var/lib/apt/lists/*
28
 
29
- # Copying actual application
30
- COPY . /app/src/
31
- RUN poetry install --only main
32
-
33
- CMD ["/usr/local/bin/python", "-m", "reworkd_platform"]
34
-
35
- FROM prod as dev
36
-
37
- RUN poetry install
 
 
 
 
 
1
+ FROM huggingface/transformers-pytorch-gpu:latest
2
 
3
+ ENV DEBIAN_FRONTEND=noninteractive
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
 
5
+ RUN apt-get update && apt-get install -y \
6
+ git \
7
+ wget \
8
+ curl \
9
+ vim \
10
+ nano \
11
+ build-essential \
12
+ python3 \
13
+ python3-pip
14
+
15
+ WORKDIR /app
16
+
17
+ COPY . .