Skip to content

Commit

Permalink
feat(docker) Adds Sasl support to base ingestion image (datahub-proje…
Browse files Browse the repository at this point in the history
…ct#5855)

* feat(docker) Adds Sasl support to base ingestion image

* Add oracle changes
  • Loading branch information
pedro93 authored and shirshanka committed Sep 8, 2022
1 parent 4661969 commit fbdb2cd
Showing 1 changed file with 53 additions and 8 deletions.
61 changes: 53 additions & 8 deletions docker/datahub-ingestion/base.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,59 @@
FROM python:3.9.9 as base

ENV DOCKERIZE_VERSION v0.6.1
ENV LIBRDKAFKA_VERSION=1.6.2
ENV CONFLUENT_KAFKA_VERSION=1.6.1

ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update && apt-get install -y \
jq \
librdkafka-dev \
python3-ldap \
libldap2-dev \
libsasl2-dev \
libsasl2-modules \
ldap-utils \
&& python -m pip install --upgrade pip wheel setuptools==57.5.0
&& 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 \
&& 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;

COPY ./base-requirements.txt requirements.txt

Expand Down

0 comments on commit fbdb2cd

Please sign in to comment.