[UI] use only one logger adapter and update Dockerfile (#2646)

* [UI] use only one logger adapter and update Dockerfile
* remove setLevel on logger
This commit is contained in:
Felix Kunde
2024-05-31 11:24:31 +02:00
committed by GitHub
parent 1210ceca72
commit d60b424d79
7 changed files with 64 additions and 65 deletions
+14 -45
View File
@@ -1,53 +1,22 @@
ARG BASE_IMAGE=registry.opensource.zalan.do/library/alpine-3.15:latest
ARG NODE_IMAGE=node:14.21.2-alpine
FROM $NODE_IMAGE AS build
COPY . /workdir
WORKDIR /workdir/app
RUN npm install &&\
npm run build
FROM $BASE_IMAGE
FROM registry.opensource.zalan.do/library/python-3.11-slim:latest
LABEL maintainer="Team ACID @ Zalando <team-acid@zalando.de>"
EXPOSE 8081
WORKDIR /app
RUN \
apk add --no-cache \
alpine-sdk \
autoconf \
automake \
ca-certificates \
libffi-dev \
libtool \
python3 \
python3-dev \
zlib-dev \
&& \
python3 -m ensurepip && \
rm -r /usr/lib/python*/ensurepip && \
pip3 install --upgrade \
gevent \
jq \
pip \
setuptools \
&& \
rm -rf \
/root/.cache \
/tmp/* \
/var/cache/apk/*
RUN apt-get -qq -y update \
# https://www.psycopg.org/docs/install.html#psycopg-vs-psycopg-binary
&& apt-get -qq -y install --no-install-recommends g++ libpq-dev python3-dev python3-distutils \
&& apt-get -qq -y clean \
&& rm -rf /var/lib/apt/lists/*
COPY requirements.txt /
COPY start_server.sh /
RUN pip3 install -r /requirements.txt
COPY requirements.txt .
COPY start_server.sh .
RUN pip install -r requirements.txt
COPY operator_ui operator_ui/
COPY operator_ui /operator_ui
COPY --from=build /workdir/operator_ui/static/build /operator_ui/static/build
ARG VERSION=dev
RUN sed -i "s/__version__ = .*/__version__ = '${VERSION}'/" /operator_ui/__init__.py
RUN sed -i "s/__version__ = .*/__version__ = '${VERSION}'/" operator_ui/__init__.py
WORKDIR /
CMD ["/usr/bin/python3", "-m", "operator_ui"]
CMD ["python", "-m", "operator_ui"]