You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kyuubi.apache.org by "cfmcgrady (via GitHub)" <gi...@apache.org> on 2023/01/31 02:22:29 UTC

[GitHub] [kyuubi-docker] cfmcgrady commented on a diff in pull request #1: Initial docker file

cfmcgrady commented on code in PR #1:
URL: https://github.com/apache/kyuubi-docker/pull/1#discussion_r1091360578


##########
.github/workflows/docker-image.yml:
##########
@@ -0,0 +1,58 @@
+#
+# 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.
+#
+
+name: Publish Docker image
+
+on:
+  push:
+    tags:
+      - '*'
+
+jobs:
+  push_to_registry:
+    name: Push Docker image to Docker Hub
+    if: ${{ startsWith(github.repository, 'apache/') }}
+    runs-on: ubuntu-22.04
+    strategy:
+       matrix:
+         include:
+           - suffix-name: ''
+             opts: '--flink-provided --spark-provided --hive-provided'
+           - suffix-name: '-spark'
+             opts: '--flink-provided --hive-provided'
+           - suffix-name: '-flink'
+             opts: '--spark-provided --hive-provided'
+           - suffix-name: '-all'
+             opts: ''
+    steps:
+      - name: Checkout
+        uses: actions/checkout@v3
+      - name: Login to Docker Hub
+        uses: docker/login-action@v2
+        with:
+          username: ${{ secrets.DOCKERHUB_USER }}
+          password: ${{ secrets.DOCKERHUB_TOKEN }}
+      - name: Build Kyuubi Docker Image
+        run: |
+          wget -O kyuubi.tgz https://archive.apache.org/dist/kyuubi/kyuubi-$(cat release/release_version)/apache-kyuubi-$(cat release/release_version)-source.tgz
+          tar -xvf kyuubi.tgz --strip-components=1
+          ./build/dist ${{ matrix.opts }} -Dmaven.javadoc.skip=true -Dmaven.scaladoc.skip=true -Drat.skip=true -Dscalastyle.skip=true -Dspotless.check.skip -DskipTests
+          docker build --tag apache/kyuubi:$(cat release/release_version)${{ matrix.suffix-name }} --file $(cat release/release_version)/*/Dockerfile .

Review Comment:
   If we want to exclude some files or directories, `.dockerignore` is a good choice.



-- 
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: dev-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org