File tree 5 files changed +17
-16
lines changed
5 files changed +17
-16
lines changed Original file line number Diff line number Diff line change @@ -69,7 +69,9 @@ RUN mkdir -p /etc/apt/keyrings \
69
69
&& echo "deb [signed-by=/etc/apt/keyrings/adoptium.asc] https://packages.adoptium.net/artifactory/deb $(awk -F= '/^VERSION_CODENAME/{print$2}' /etc/os-release) main" | tee /etc/apt/sources.list.d/adoptium.list \
70
70
&& apt-get update \
71
71
&& apt-get -y dist-upgrade \
72
- && apt-get -y install temurin-17-jdk
72
+ && apt-get -y install temurin-17-jdk \
73
+ && export ARCH=$(uname -m | sed -r 's/aarch64/arm64/g' | awk '!/arm64/{$0="amd64"}1' ) \
74
+ && echo networkaddress.cache.ttl=1 >> /usr/lib/jvm/temurin-17-jdk-$ARCH/conf/security/java.security \
73
75
74
76
# Cleanup apt
75
77
RUN apt-get -y --purge autoremove \
@@ -87,13 +89,10 @@ RUN pip3 install pyyaml==5.4.1
87
89
# 4. /pulsar - hadoop writes to this directory
88
90
RUN mkdir /pulsar && chmod g+w /pulsar
89
91
90
- ENV JAVA_HOME /usr/lib/jvm/temurin-17-jdk-amd64
91
- RUN echo networkaddress.cache.ttl=1 >> /usr/lib/jvm/temurin-17-jdk-amd64/conf/security/java.security
92
92
ADD target/python-client/ /pulsar/pulsar-client
93
93
94
94
ENV PULSAR_ROOT_LOGGER=INFO,CONSOLE
95
95
96
-
97
96
COPY --from=pulsar /pulsar /pulsar
98
97
WORKDIR /pulsar
99
98
Original file line number Diff line number Diff line change 31
31
<packaging >pom</packaging >
32
32
33
33
<properties >
34
+ <pythonClientBuildArch >x86_64</pythonClientBuildArch >
34
35
<skipBuildPythonClient >false</skipBuildPythonClient >
35
36
<skipCopyPythonClients >false</skipCopyPythonClients >
36
37
</properties >
79
80
<executable >${project.basedir} /../../pulsar-client-cpp/docker/build-wheels.sh</executable >
80
81
<arguments >
81
82
<!-- build python 3.8 -->
82
- <argument >3.8 cp38-cp38 manylinux2014 x86_64 </argument >
83
+ <argument >3.8 cp38-cp38 manylinux2014 ${pythonClientBuildArch} </argument >
83
84
</arguments >
84
85
</configuration >
85
86
</execution >
Original file line number Diff line number Diff line change 20
20
21
21
set -x
22
22
23
+ # TODO: remove these lines once grpcio doesn't need to compile from source on ARM64 platform
24
+ ARCH=$( uname -m | sed -r ' s/aarch64/arm64/g' | awk ' !/arm64/{$0="amd64"}1' )
25
+ if [ " ${ARCH} " == " arm64" ]; then
26
+ apt update
27
+ apt -y install build-essential python3-dev
28
+ fi
29
+
23
30
PYTHON_MAJOR_MINOR=$( python3 -V | sed -E ' s/.* ([[:digit:]]+)\.([[:digit:]]+).*/\1\2/' )
24
31
WHEEL_FILE=$( ls /pulsar/pulsar-client | grep " cp${PYTHON_MAJOR_MINOR} " )
25
32
pip3 install /pulsar/pulsar-client/${WHEEL_FILE} [all]
Original file line number Diff line number Diff line change @@ -46,10 +46,9 @@ RUN mkdir -p /etc/apt/keyrings \
46
46
&& echo "deb [signed-by=/etc/apt/keyrings/adoptium.asc] https://packages.adoptium.net/artifactory/deb $(awk -F= '/^VERSION_CODENAME/{print$2}' /etc/os-release) main" | tee /etc/apt/sources.list.d/adoptium.list \
47
47
&& apt-get update \
48
48
&& apt-get -y dist-upgrade \
49
- && apt-get -y install temurin-17-jdk
50
-
51
- ENV JAVA_HOME /usr/lib/jvm/temurin-17-jdk-amd64
52
- RUN echo networkaddress.cache.ttl=1 >> /usr/lib/jvm/temurin-17-jdk-amd64/conf/security/java.security
49
+ && apt-get -y install temurin-17-jdk \
50
+ && export ARCH=$(uname -m | sed -r 's/aarch64/arm64/g' | awk '!/arm64/{$0="amd64"}1' ) \
51
+ && echo networkaddress.cache.ttl=1 >> /usr/lib/jvm/temurin-17-jdk-$ARCH/conf/security/java.security
53
52
54
53
# /pulsar/bin/watch-znode.py requires python3-kazoo
55
54
# /pulsar/bin/pulsar-managed-ledger-admin requires python3-protobuf
Original file line number Diff line number Diff line change @@ -29,13 +29,8 @@ RUN apt-get install -y procps curl git build-essential
29
29
30
30
ENV GOLANG_VERSION 1.15.8
31
31
32
- RUN curl -sSL https://golang.org/dl/go$GOLANG_VERSION.linux-amd64.tar.gz \
33
- | tar -C /usr/local -xz
34
-
35
- # RUN wget https://dl.google.com/go/go1.13.3.linux-amd64.tar.gz && tar -xvf go1.13.3.linux-amd64.tar.gz && mv go /usr/local
36
- # RUN export GOROOT=/usr/local/go && export GOPATH=$HOME/go && export PATH=$GOPATH/bin:$GOROOT/bin:$PATH
37
- # RUN echo "export GOROOT=/usr/local/go" >> ~/.profile && echo "export GOPATH=$HOME/go" >> ~/.profile && echo "export PATH=$GOPATH/bin:$GOROOT/bin:$PATH" >> ~/.profile
38
-
32
+ RUN export ARCH=$(uname -m | sed -r 's/aarch64/arm64/g' | awk '!/arm64/{$0="amd64"}1' ) \
33
+ && curl -sSL https://golang.org/dl/go$GOLANG_VERSION.linux-$ARCH.tar.gz | tar -C /usr/local -xz
39
34
ENV PATH /usr/local/go/bin:$PATH
40
35
41
36
RUN mkdir -p /go/src /go/bin && chmod -R 777 /go
You can’t perform that action at this time.
0 commit comments