Skip to content

Commit dc3aec8

Browse files
Merge pull request #14 from intelops/feat/dockerfile
added docekrfile
2 parents ac33bc2 + 4dc2fae commit dc3aec8

File tree

2 files changed

+33
-1
lines changed

2 files changed

+33
-1
lines changed

Dockerfile

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
FROM python:3.10-slim as build
2+
3+
RUN apt-get update
4+
RUN apt-get install -y --no-install-recommends build-essential gcc
5+
6+
WORKDIR /usr/app
7+
8+
RUN python -m venv /usr/app/venv
9+
ENV PATH="/usr/app/venv/bin:$PATH"
10+
11+
copy requirements.txt .
12+
13+
RUN pip install -r requirements.txt
14+
15+
# FROM python:3.12.0b3-slim@sha256:8e3ef64883278384c49293caf631d614b4bfdac7bb494d44e17cf2d711ce2652
16+
FROM python:3.10-slim@sha256:2bac43769ace90ebd3ad83e5392295e25dfc58e58543d3ab326c3330b505283d
17+
18+
RUN groupadd -g 999 python && \
19+
useradd -r -u 999 -g python python
20+
21+
RUN mkdir /usr/app && chown python:python /usr/app
22+
WORKDIR /usr/app
23+
COPY --chown=python:python --from=build /usr/app/venv ./venv
24+
COPY --chown=python:python . .
25+
26+
USER 999
27+
28+
ENV PATH="/usr/app/venv/bin:$PATH"
29+
30+
CMD ["bash"]
31+

requirements.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@ click==8.1.3
33
clickhouse-driver==0.2.6
44
requests==2.31.0
55
questionary==1.10.0
6-
tabulate==0.9.0
6+
tabulate==0.9.0
7+
kubernetes==27.2.0

0 commit comments

Comments
 (0)