2022-12-08 12:54:21 -06:00
|
|
|
FROM python:3.10 as base
|
2022-06-27 14:08:16 +05:30
|
|
|
|
2022-09-07 17:51:06 +01:00
|
|
|
ENV DOCKERIZE_VERSION v0.6.1
|
|
|
|
ENV LIBRDKAFKA_VERSION=1.6.2
|
|
|
|
ENV CONFLUENT_KAFKA_VERSION=1.6.1
|
|
|
|
|
|
|
|
ENV DEBIAN_FRONTEND noninteractive
|
|
|
|
|
2022-06-27 17:28:12 +05:30
|
|
|
RUN apt-get update && apt-get install -y \
|
2022-09-07 17:51:06 +01:00
|
|
|
&& if [ $(arch) = "aarch64" ]; then \
|
|
|
|
DOCKERIZE_ARCH='aarch64';\
|
|
|
|
elif [ $(arch) = "x86_64" ]; then \
|
|
|
|
DOCKERIZE_ARCH='amd64'; \
|
|
|
|
else \
|
|
|
|
echo >&2 "Unsupported architecture $(arch)" ; exit 1; \
|
|
|
|
fi \
|
|
|
|
&& apt-get install -y -qq \
|
|
|
|
# gcc \
|
|
|
|
make \
|
|
|
|
jq \
|
|
|
|
python3-ldap \
|
|
|
|
libldap2-dev \
|
|
|
|
libsasl2-dev \
|
|
|
|
libsasl2-modules \
|
|
|
|
libaio1 \
|
|
|
|
libsasl2-modules-gssapi-mit \
|
|
|
|
krb5-user \
|
|
|
|
wget \
|
|
|
|
zip \
|
|
|
|
unzip \
|
|
|
|
ldap-utils \
|
2022-11-04 17:13:18 +02:00
|
|
|
openjdk-11-jre-headless \
|
2022-09-07 17:51:06 +01:00
|
|
|
&& curl -L https://github.com/treff7es/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-${DOCKERIZE_ARCH}-$DOCKERIZE_VERSION.tar.gz | tar -C /usr/local/bin -xzv \
|
|
|
|
&& python -m pip install --upgrade pip wheel setuptools==57.5.0 \
|
|
|
|
&& curl -Lk -o /root/librdkafka-${LIBRDKAFKA_VERSION}.tar.gz https://github.com/edenhill/librdkafka/archive/v${LIBRDKAFKA_VERSION}.tar.gz \
|
|
|
|
&& tar -xzf /root/librdkafka-${LIBRDKAFKA_VERSION}.tar.gz -C /root \
|
|
|
|
&& cd /root/librdkafka-${LIBRDKAFKA_VERSION} \
|
|
|
|
&& ./configure --prefix /usr && make && make install && make clean && ./configure --clean \
|
|
|
|
&& apt-get remove -y make
|
|
|
|
|
|
|
|
RUN if [ $(arch) = "x86_64" ]; then \
|
|
|
|
mkdir /opt/oracle && \
|
|
|
|
cd /opt/oracle && \
|
|
|
|
wget --no-verbose -c https://download.oracle.com/otn_software/linux/instantclient/216000/instantclient-basic-linux.x64-21.6.0.0.0dbru.zip && \
|
|
|
|
unzip instantclient-basic-linux.x64-21.6.0.0.0dbru.zip && \
|
|
|
|
rm instantclient-basic-linux.x64-21.6.0.0.0dbru.zip && \
|
|
|
|
sh -c "echo /opt/oracle/instantclient_21_6 > /etc/ld.so.conf.d/oracle-instantclient.conf" && \
|
|
|
|
ldconfig; \
|
|
|
|
else \
|
|
|
|
mkdir /opt/oracle && \
|
|
|
|
cd /opt/oracle && \
|
|
|
|
wget --no-verbose -c https://download.oracle.com/otn_software/linux/instantclient/191000/instantclient-basic-linux.arm64-19.10.0.0.0dbru.zip && \
|
|
|
|
unzip instantclient-basic-linux.arm64-19.10.0.0.0dbru.zip && \
|
|
|
|
rm instantclient-basic-linux.arm64-19.10.0.0.0dbru.zip && \
|
|
|
|
sh -c "echo /opt/oracle/instantclient_19_10 > /etc/ld.so.conf.d/oracle-instantclient.conf" && \
|
|
|
|
ldconfig; \
|
|
|
|
fi;
|
2022-06-27 17:28:12 +05:30
|
|
|
|
2022-06-27 14:08:16 +05:30
|
|
|
COPY ./base-requirements.txt requirements.txt
|
|
|
|
|
2022-07-12 12:37:47 +05:30
|
|
|
RUN pip install -r requirements.txt && \
|
2022-09-07 17:08:49 -07:00
|
|
|
pip uninstall -y acryl-datahub
|