This is an automated email from the ASF dual-hosted git repository.

technoboy pushed a commit to branch branch-2.11
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/branch-2.11 by this push:
     new 5a16a913c3f [fix][build] Update base image to 22.04 and remove the 
python client building (#20770)
5a16a913c3f is described below

commit 5a16a913c3ffa40422378be002e1c80ef3a881c7
Author: Lishen Yao <[email protected]>
AuthorDate: Tue Jul 11 11:00:19 2023 +0800

    [fix][build] Update base image to 22.04 and remove the python client 
building (#20770)
---
 build/docker/Dockerfile                        |  2 +-
 docker/pulsar/Dockerfile                       |  3 +-
 docker/pulsar/pom.xml                          | 45 --------------------------
 docker/pulsar/scripts/install-pulsar-client.sh |  8 +----
 tests/docker-images/java-test-image/Dockerfile |  2 +-
 5 files changed, 4 insertions(+), 56 deletions(-)

diff --git a/build/docker/Dockerfile b/build/docker/Dockerfile
index 21868cc8b15..eab3d9da737 100644
--- a/build/docker/Dockerfile
+++ b/build/docker/Dockerfile
@@ -17,7 +17,7 @@
 # under the License.
 #
 
-FROM ubuntu:20.04
+FROM ubuntu:22.04
 
 # prepare the directory for pulsar related files
 RUN mkdir /pulsar
diff --git a/docker/pulsar/Dockerfile b/docker/pulsar/Dockerfile
index 6450668ccd2..e504f5ecbea 100644
--- a/docker/pulsar/Dockerfile
+++ b/docker/pulsar/Dockerfile
@@ -49,7 +49,7 @@ RUN chmod g+w /pulsar/lib/presto
 ### Create 2nd stage from Ubuntu image
 ### and add OpenJDK and Python dependencies (for Pulsar functions)
 
-FROM ubuntu:20.04
+FROM ubuntu:22.04
 
 ARG DEBIAN_FRONTEND=noninteractive
 ARG UBUNTU_MIRROR=mirror://mirrors.ubuntu.com/mirrors.txt
@@ -79,7 +79,6 @@ RUN mkdir /pulsar && chmod g+w /pulsar
 
 ENV JAVA_HOME /usr/lib/jvm/java-17-openjdk-amd64
 RUN echo networkaddress.cache.ttl=1 >> 
/usr/lib/jvm/java-17-openjdk-amd64/conf/security/java.security
-ADD target/python-client/ /pulsar/pulsar-client
 
 ENV PULSAR_ROOT_LOGGER=INFO,CONSOLE
 
diff --git a/docker/pulsar/pom.xml b/docker/pulsar/pom.xml
index 42b3c7bb87b..1f1a29807e9 100644
--- a/docker/pulsar/pom.xml
+++ b/docker/pulsar/pom.xml
@@ -57,51 +57,6 @@
       <id>docker</id>
       <build>
         <plugins>
-          <!-- build Python client, copy the wheel file and then build docker 
image -->
-          <plugin>
-            <groupId>org.codehaus.mojo</groupId>
-            <artifactId>exec-maven-plugin</artifactId>
-            <version>${exec-maven-plugin.version}</version>
-            <executions>
-              <execution>
-                <id>build-pulsar-clients-python-35</id>
-                <phase>compile</phase>
-                <goals>
-                  <goal>exec</goal>
-                </goals>
-                <configuration>
-                  <skip>${skipBuildPythonClient}</skip>
-                  
<workingDirectory>${project.basedir}/target</workingDirectory>
-                  
<executable>${project.basedir}/../../pulsar-client-cpp/docker/build-wheels.sh</executable>
-                  <arguments>
-                    <!-- build python 3.8 -->
-                    <argument>3.8 cp38-cp38 manylinux2014 x86_64</argument>
-                  </arguments>
-                </configuration>
-              </execution>
-            </executions>
-          </plugin>
-          <plugin>
-            <groupId>org.apache.maven.plugins</groupId>
-            <artifactId>maven-antrun-plugin</artifactId>
-            <executions>
-              <execution>
-                <id>copy-pulsar-clients-python</id>
-                <phase>compile</phase>
-                <goals>
-                  <goal>run</goal>
-                </goals>
-                <configuration>
-                  <skip>${skipCopyPythonClients}</skip>
-                  <target>
-                    <echo>copy python wheel file</echo>
-                    <mkdir dir="${basedir}/target/python-client"/>
-                    <copydir 
src="${basedir}/../../pulsar-client-cpp/python/wheelhouse" 
dest="${basedir}/target/python-client"/>
-                  </target>
-                </configuration>
-              </execution>
-            </executions>
-          </plugin>
           <plugin>
             <groupId>com.spotify</groupId>
             <artifactId>dockerfile-maven-plugin</artifactId>
diff --git a/docker/pulsar/scripts/install-pulsar-client.sh 
b/docker/pulsar/scripts/install-pulsar-client.sh
index b4b2ec8ac2d..1a1ac0f1cad 100755
--- a/docker/pulsar/scripts/install-pulsar-client.sh
+++ b/docker/pulsar/scripts/install-pulsar-client.sh
@@ -20,10 +20,4 @@
 
 set -x
 
-PYTHON_MAJOR_MINOR=$(python3 -V | sed -E 's/.* 
([[:digit:]]+)\.([[:digit:]]+).*/\1\2/')
-echo $PYTHON_MAJOR_MINOR
-ls /pulsar/pulsar-client
-uname -a
-WHEEL_FILE=$(ls /pulsar/pulsar-client | grep "cp${PYTHON_MAJOR_MINOR}")
-echo WHEEL_FILE=$WHEEL_FILE
-pip3 install /pulsar/pulsar-client/${WHEEL_FILE}[all]
+pip3 install 'pulsar-client[all]==3.2.0'
diff --git a/tests/docker-images/java-test-image/Dockerfile 
b/tests/docker-images/java-test-image/Dockerfile
index b7f12b75968..d712c83a425 100644
--- a/tests/docker-images/java-test-image/Dockerfile
+++ b/tests/docker-images/java-test-image/Dockerfile
@@ -17,7 +17,7 @@
 # under the License.
 #
 
-FROM ubuntu:20.04
+FROM ubuntu:22.04
 
 RUN groupadd -g 10001 pulsar
 RUN adduser -u 10000 --gid 10001 --disabled-login --disabled-password --gecos 
'' pulsar

Reply via email to