Copilot commented on code in PR #12690:
URL: https://github.com/apache/gluten/pull/12690#discussion_r3713788130


##########
dev/docker/cudf/Dockerfile.centos-9-jdk17-cuda13.1-cudf:
##########
@@ -0,0 +1,36 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+FROM quay.io/centos/centos:stream9
+ENV CUDA_ARCHITECTURES=75
+ENV 
LD_LIBRARY_PATH=/opt/gluten/ep/build-velox/build/velox_ep/_build/release/_deps/curl-build/lib:$LD_LIBRARY_PATH
+ENV CC=/opt/rh/gcc-toolset-14/root/bin/gcc \
+    CXX=/opt/rh/gcc-toolset-14/root/bin/g++
+
+RUN dnf config-manager --add-repo 
"https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/cuda-rhel9.repo";;
 \
+    dnf update; \
+    dnf install -y sudo patch maven perl git gcc-toolset-14 cuda-toolkit-13-1 
&& \
+    dnf autoremove -y && dnf clean all; \
+    git clone --depth=1 https://github.com/apache/incubator-gluten /opt/gluten 
&& \
+    cd /opt/gluten && \
+    source /opt/rh/gcc-toolset-14/enable && \
+    bash ./dev/buildbundle-veloxbe.sh --run_setup_script=ON --build_arrow=ON 
--spark_version=3.5 --build_tests=ON --build_benchmarks=ON --enable_s3=ON 
--enable_gcs=ON --enable_abfs=ON --enable_gpu=ON && \
+    rm -rf /opt/gluten && \
+    rm -rf /root/.cache/ccache   

Review Comment:
   The image is named `jdk17` but the Dockerfile doesn’t explicitly install a 
JDK 17 package. On CentOS Stream 9, installing `maven` typically pulls in some 
Java runtime, which can be a different Java version than intended (and can 
reintroduce JDK 8). Install `java-17-openjdk-devel` (and/or set `JAVA_HOME`) 
explicitly to ensure the image consistently matches the tag and avoids CI 
variability.



##########
dev/docker/cudf/Dockerfile.centos-9-jdk17-cuda13.1-cudf:
##########
@@ -0,0 +1,36 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+FROM quay.io/centos/centos:stream9
+ENV CUDA_ARCHITECTURES=75
+ENV 
LD_LIBRARY_PATH=/opt/gluten/ep/build-velox/build/velox_ep/_build/release/_deps/curl-build/lib:$LD_LIBRARY_PATH
+ENV CC=/opt/rh/gcc-toolset-14/root/bin/gcc \
+    CXX=/opt/rh/gcc-toolset-14/root/bin/g++
+
+RUN dnf config-manager --add-repo 
"https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/cuda-rhel9.repo";;
 \
+    dnf update; \
+    dnf install -y sudo patch maven perl git gcc-toolset-14 cuda-toolkit-13-1 
&& \
+    dnf autoremove -y && dnf clean all; \

Review Comment:
   `dnf update` is missing `-y`, which can cause non-interactive Docker builds 
to fail/hang. Also, the command chain uses `;`/`\\` between steps so failures 
won’t necessarily stop subsequent steps. Prefer `dnf -y update` and `&&` 
chaining so the image build fails fast and deterministically when a step fails.



##########
dev/docker/cudf/Dockerfile.centos-9-jdk17-cuda13.1-cudf:
##########
@@ -0,0 +1,36 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+FROM quay.io/centos/centos:stream9
+ENV CUDA_ARCHITECTURES=75
+ENV 
LD_LIBRARY_PATH=/opt/gluten/ep/build-velox/build/velox_ep/_build/release/_deps/curl-build/lib:$LD_LIBRARY_PATH
+ENV CC=/opt/rh/gcc-toolset-14/root/bin/gcc \
+    CXX=/opt/rh/gcc-toolset-14/root/bin/g++
+
+RUN dnf config-manager --add-repo 
"https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/cuda-rhel9.repo";;
 \
+    dnf update; \
+    dnf install -y sudo patch maven perl git gcc-toolset-14 cuda-toolkit-13-1 
&& \
+    dnf autoremove -y && dnf clean all; \
+    git clone --depth=1 https://github.com/apache/incubator-gluten /opt/gluten 
&& \

Review Comment:
   The PR description and existing image naming refer to `apache/gluten`, but 
the Dockerfile clones `apache/incubator-gluten`. If the incubator repo is not 
the intended source, the built dependencies may drift from what CI expects. 
Consider cloning the canonical repo for this project (and optionally pinning to 
a specific commit/tag) to improve reproducibility of the published image.



##########
.github/workflows/docker_image.yml:
##########
@@ -145,6 +145,37 @@ jobs:
           push: true
           tags: ${{ env.DOCKERHUB_REPO }}:centos-9-jdk17-cuda12.9-cudf
 
+  build-centos-9-jdk17-cuda13_1-cudf:
+    if: ${{ startsWith(github.repository, 'apache/') }}
+    runs-on: ubuntu-22.04
+
+    steps:
+      - name: "node-cleanup" # by default the free runner does not have enough 
disk space
+        run: |
+          sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc 
/opt/hostedtoolcache/CodeQL
+          sudo docker image prune --all --force
+          sudo docker builder prune -a

Review Comment:
   `docker builder prune -a` is interactive unless `--force` is provided, which 
can cause the job to hang. Add `--force` to make this step non-interactive like 
the `docker image prune` line.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to