forked from zabbix-tooling/k8s-zabbix
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
32 lines (26 loc) · 1.07 KB
/
Dockerfile
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
FROM python:3.11
LABEL maintainer="[email protected]"
LABEL Description="zabbix-kubernetes - efficent kubernetes monitoring for zabbix"
MAINTAINER [email protected]
ENV K8S_API_HOST ""
ENV K8S_API_TOKEN ""
ENV ZABBIX_SERVER "zabbix"
ENV ZABBIX_HOST "k8s"
ENV CRYPTOGRAPHY_DONT_BUILD_RUST "1"
WORKDIR /app
COPY --chown=nobody:users Pipfile /app/
RUN apt-get update -y
RUN apt-get upgrade -y
RUN apt-get dist-upgrade -y
RUN apt-get install libffi-dev libffi8 libssl-dev bash screen ncdu -y
RUN pip install --root-user-action=ignore --upgrade pip && pip install --root-user-action=ignore pipenv
RUN PIPENV_USE_SYSTEM=1 pipenv install --skip-lock --system
RUN apt-get remove base libssl-dev libffi-dev gcc -y
RUN apt-get autoremove -y
RUN rm -rf /var/lib/apt/lists/* /root/.cache
COPY --chown=nobody:users base /app/base
COPY --chown=nobody:users k8sobjects /app/k8sobjects
COPY --chown=nobody:users check_kubernetesd /app/check_kubernetesd
COPY --chown=nobody:users config_default.ini /app/config_default.ini
USER nobody
ENTRYPOINT [ "/app/check_kubernetesd" ]