You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@uniffle.apache.org by GitBox <gi...@apache.org> on 2022/08/05 12:41:21 UTC

[GitHub] [incubator-uniffle] wangao1236 opened a new pull request, #132: Add dockerfile of rss

wangao1236 opened a new pull request, #132:
URL: https://github.com/apache/incubator-uniffle/pull/132

   <!--
   Thanks for sending a pull request!  Here are some tips for you:
     1. If this is your first time, please read our contributor guidelines: https://github.com/Tencent/Firestorm/blob/master/CONTRIBUTING.md
     2. Ensure you have added or run the appropriate tests for your PR
     3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP]XXXX Your PR title ...'.
     4. Be sure to keep the PR description updated to reflect all changes.
     5. Please write your PR title to summarize what this PR proposes.
     6. If possible, provide a concise example to reproduce the issue for a faster review.
   -->
   
   ### What changes were proposed in this pull request?
   To solve issue #48 ,I add the Dockerfile for uniffle.
   
   
   ### Why are the changes needed?
   <!--
   Please clarify why the changes are needed. For instance,
     1. If you propose a new API, clarify the use case for a new API.
     2. If you fix a bug, you can clarify why it is a bug.
   -->
   
   
   ### Does this PR introduce _any_ user-facing change?
   <!--
   Note that it means *any* user-facing change including all aspects such as the documentation fix.
   If yes, please clarify the previous behavior and the change this PR proposes - provide the console output, description and/or an example to show the behavior difference if possible.
   If possible, please also clarify if this is a user-facing change compared to the released versions or within the unreleased branches such as master.
   If no, write 'No'.
   -->
   
   
   ### How was this patch tested?
   <!--
   If tests were added, say they were added here. Please make sure to add some test cases that check the changes thoroughly including negative and positive cases if possible.
   If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future.
   If tests were not added, please describe why they were not added and/or why it was difficult to add.
   -->
   


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] wangao1236 commented on pull request #132: Add dockerfile of rss

Posted by GitBox <gi...@apache.org>.
wangao1236 commented on PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#issuecomment-1206418933

   #48 


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938847189


##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,40 @@
+#!/bin/bash
+
+basedir='/data/rssadmin/rss'
+cd $basedir || exit
+
+coordinator_conf=$basedir'/conf/coordinator.conf'
+echo "coordinator_conf: $coordinator_conf"
+server_conf=$basedir'/conf/server.conf'
+echo "server_conf: $server_conf"
+
+
+if [ "$SERVICE_NAME" == "coordinator" ];then
+
+    bash ${basedir}/bin/start-coordinator.sh &
+    sleep 10
+    while : ; do
+        pid=$(/usr/bin/lsof -i:"${COORDINATOR_RPC_PORT}" -sTCP:LISTEN)
+        if [ "$pid" = "" ]; then
+          break
+        else
+          echo "coordinator pid:$pid is alive"
+          sleep 10
+        fi
+    done
+fi
+
+if [ "$SERVICE_NAME" == "server" ];then
+
+    bash ${basedir}/bin/start-shuffle-server.sh &
+    sleep 10
+    while : ; do
+        pid=$(/usr/bin/lsof -i:"$SERVER_RPC_PORT" -sTCP:LISTEN)
+        if [ "$pid" = "" ]; then
+          break
+        else
+          echo "shuffle server pid:$pid is alive"
+          sleep 10
+        fi
+    done
+fi

Review Comment:
   We need a new line at the end of the file.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r940154898


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > I think we can use dependency_cache to save our build time
   > 
   > for example: FROM openjdk:8-jdk-slim as dependency_cache
   
   It's great. Could you raise a follow-up pr which uses dependency_cache? 



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r940159190


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > > > Seems `8-jdk-slim` image is based on Debian stable, which is fine. Can we use `8-jre-slim` here?
   > > 
   > > 
   > > What's your reason?
   > 
   > It's smaller.
   
   It may need more tests. If `8-jdk-slim` is fine, we can choose it first. When our e2e test is ready, wen can use e2e test to verify the `8-jre-slim`.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939602841


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,46 @@
+#
+# 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 openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \

Review Comment:
   It's ok for us if there are no big conflicts. We shouldn't consider the kerberos dependency here.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#issuecomment-1206502865

   Could you remove the file https://github.com/apache/incubator-uniffle/blob/master/deploy/kubernetes/docker/.gitkeep? Because the directory `docker` has files, don't need a keep file.


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939602699


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,46 @@
+#
+# 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 openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \
+      && apt-get clean && rm -rf /var/lib/apt/lists/*
+
+RUN useradd -ms /bin/bash rssadmin
+RUN mkdir -p /data/rssadmin/
+RUN chown -R rssadmin:rssadmin /data
+USER rssadmin
+
+COPY rss-${RSS_VERSION}.tgz /data/rssadmin
+RUN tar -xvf /data/rssadmin/rss-${RSS_VERSION}.tgz -C /data/rssadmin
+RUN mv /data/rssadmin/rss-${RSS_VERSION} /data/rssadmin/rss
+RUN rm -rf /data/rssadmin/rss-${RSS_VERSION}.tgz
+
+COPY start.sh /data/rssadmin/rss/bin
+
+COPY hadoop-${HADOOP_VERSION}.tar.gz /data/rssadmin
+RUN tar -zxvf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz -C /data/rssadmin
+RUN mv /data/rssadmin/hadoop-${HADOOP_VERSION} /data/rssadmin/hadoop
+RUN rm -rf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz
+COPY hadoopconfig/ /data/rssadmin/hadoop/etc/hadoop

Review Comment:
   Yes.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939602997


##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+#
+# 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.
+#
+
+basedir='/data/rssadmin/rss'
+cd $basedir || exit
+
+coordinator_conf=$basedir'/conf/coordinator.conf'
+echo "coordinator_conf: $coordinator_conf"
+server_conf=$basedir'/conf/server.conf'
+echo "server_conf: $server_conf"
+
+
+if [ "$SERVICE_NAME" == "coordinator" ];then
+
+    bash ${basedir}/bin/start-coordinator.sh &

Review Comment:
   Could you give me your reason?



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939511502


##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz
+/deploy/kubernetes/hadoopconfig/*

Review Comment:
   Why do we use absolute path here? if `hadoopconfig` is useful, why do we add it to `.gitignore` file?



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] zuston commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
zuston commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939606202


##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+#
+# 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.
+#
+
+basedir='/data/rssadmin/rss'
+cd $basedir || exit
+
+coordinator_conf=$basedir'/conf/coordinator.conf'
+echo "coordinator_conf: $coordinator_conf"
+server_conf=$basedir'/conf/server.conf'
+echo "server_conf: $server_conf"
+
+
+if [ "$SERVICE_NAME" == "coordinator" ];then
+
+    bash ${basedir}/bin/start-coordinator.sh &

Review Comment:
   start.sh will monitor the process existence, if the coordinator startup failed, we should exit directly, instead of waiting the non-existence PID and then exit 0



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] kaijchen commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
kaijchen commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939802935


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   Seems `8-jdk-slim` image is based on Debian stable, which is fine.
   Can we use `8-jre-slim` here?



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938849635


##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz
+/deploy/kubernetes/hadoopconfig/*

Review Comment:
   We need a new line at the end of the file.
   Maybe we don't need `hadoopconfig` directory.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938836561


##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz

Review Comment:
   Could we remove this two files?



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r940154898


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > I think we can use dependency_cache to save our build time
   > 
   > for example: FROM openjdk:8-jdk-slim as dependency_cache
   
   It's great. Could you raise a follow-up pr which uses dependency_cache? If this pr don't have big problems, let's merge this pr quikly.



##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > I think we can use dependency_cache to save our build time
   > 
   > for example: FROM openjdk:8-jdk-slim as dependency_cache
   
   It's great. Could you raise a follow-up pr which uses dependency_cache? If this pr don't have big problems, let's merge this pr quickly.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] wangao1236 commented on pull request #132: Add dockerfile of rss

Posted by GitBox <gi...@apache.org>.
wangao1236 commented on PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#issuecomment-1206404515

   /assign @jerqi 


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] czy006 commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
czy006 commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939640427


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   I think we can use dependency_cache to save our build time
   
   for example:
   FROM openjdk:8-jdk-slim as dependency_cache



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] kaijchen commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
kaijchen commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939805837


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > > Seems `8-jdk-slim` image is based on Debian stable, which is fine. Can we use `8-jre-slim` here?
   > 
   > What's your reason?
   
   It's smaller.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939602841


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,46 @@
+#
+# 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 openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \

Review Comment:
    We shouldn't consider the kerberos dependency here. It's ok for us if there are no big conflicts, it will be convenient to modify Dockerfile after we merge https://github.com/apache/incubator-uniffle/pull/53



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#issuecomment-1210065277

   @zuston @kaijchen @frankliee @czy006 Thanks for your review, if you have any other suggestion, you can raise a follow-up pr. Merged.


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi merged pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi merged PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938839086


##########
deploy/kubernetes/docker/build.sh:
##########
@@ -0,0 +1,78 @@
+#!/bin/bash

Review Comment:
   We need an Apache license.



##########
deploy/kubernetes/docker/build.sh:
##########
@@ -0,0 +1,78 @@
+#!/bin/bash
+
+function exit_with_usage() {
+  set +x
+  echo "./build.sh - Tool for building docker images of Remote Shuffle Service"
+  echo ""
+  echo "Usage:"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  echo "| ./build.sh [--hadoop-version <hadoop version>] [--registry <registry url>]                           |"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  exit 1
+}
+
+UNKNOWN_REGISTRY="UNKNOWN_REGISTRY"
+REGISTRY=$UNKNOWN_REGISTRY
+
+HADOOP_VERSION=3.2.3
+while (( "$#" )); do
+  case $1 in
+    --registry)
+      REGISTRY="$2"
+      shift
+      ;;
+    --hadoop-version)
+      HADOOP_VERSION="$2"
+      shift
+      ;;
+    --help)
+      exit_with_usage
+      ;;
+    --*)
+      echo "Error: $1 is not supported"
+      exit_with_usage
+      ;;
+    -*)
+      break
+      ;;
+    *)
+      echo "Error: $1 is not supported"
+      exit_with_usage
+      ;;
+  esac
+  shift
+done
+
+if [ "$REGISTRY" == $UNKNOWN_REGISTRY ]; \
+  then echo "please set registry url"; exit; \
+fi
+
+HADOOP_FILE=hadoop-${HADOOP_VERSION}.tar.gz
+HADOOP_URL=https://archive.apache.org/dist/hadoop/core/hadoop-${HADOOP_VERSION}/${HADOOP_FILE}
+echo "HADOOP_URL is $HADOOP_URL"
+if [ ! -e "$HADOOP_FILE" ]; \
+  then wget "$HADOOP_URL"; \
+  else echo "${HADOOP_FILE} has been downloaded"; \
+fi
+
+RSS_DIR=../../..
+cd $RSS_DIR || exit
+RSS_VERSION=$(mvn help:evaluate -Dexpression=project.version 2>/dev/null | grep -v "INFO" | grep -v "WARNING" | tail -n 1)
+RSS_FILE=rss-${RSS_VERSION}.tgz
+if [ ! -e "$RSS_FILE" ]; \
+  then sh build_distribution.sh \
+  else echo "$RSS_FILE has been built"; \
+fi
+cd "$OLDPWD" || exit
+cp "$RSS_DIR/$RSS_FILE" .
+
+IMAGE=$REGISTRY/rss-server:$RSS_VERSION
+
+echo "building image: $IMAGE"
+docker build -t "$IMAGE" \
+             --build-arg RSS_VERSION="$RSS_VERSION" \
+             --build-arg HADOOP_VERSION="$HADOOP_VERSION" \
+             -f Dockerfile --no-cache .
+
+echo "pushing image: $IMAGE"
+docker push "$IMAGE"

Review Comment:
   We need a new line at the end of the file.



##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,40 @@
+#!/bin/bash

Review Comment:
   We need an Apache license.



##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz

Review Comment:
   Could we remove this two files?



##########
deploy/kubernetes/docker/build.sh:
##########
@@ -0,0 +1,78 @@
+#!/bin/bash
+
+function exit_with_usage() {
+  set +x
+  echo "./build.sh - Tool for building docker images of Remote Shuffle Service"
+  echo ""
+  echo "Usage:"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  echo "| ./build.sh [--hadoop-version <hadoop version>] [--registry <registry url>]                           |"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  exit 1
+}
+
+UNKNOWN_REGISTRY="UNKNOWN_REGISTRY"
+REGISTRY=$UNKNOWN_REGISTRY
+
+HADOOP_VERSION=3.2.3

Review Comment:
   Should we use Hadoop version 2.8.5? Because we use the version in other modules of Uniffle, we should keep consistent with them.



##########
deploy/kubernetes/docker/hadoopconfig/.gitkeep:
##########
@@ -0,0 +1,16 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more

Review Comment:
   Could we remove this file? Why do we add this file?



##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \
+      && apt-get clean && rm -rf /var/lib/apt/lists/*
+
+RUN useradd -ms /bin/bash rssadmin
+RUN mkdir -p /data/rssadmin/
+RUN chown -R rssadmin:rssadmin /data
+USER rssadmin
+
+COPY rss-${RSS_VERSION}.tgz /data/rssadmin
+RUN tar -xvf /data/rssadmin/rss-${RSS_VERSION}.tgz -C /data/rssadmin
+RUN mv /data/rssadmin/rss-${RSS_VERSION} /data/rssadmin/rss
+RUN rm -rf /data/rssadmin/rss-${RSS_VERSION}.tgz
+
+COPY start.sh /data/rssadmin/rss/bin
+
+COPY hadoop-${HADOOP_VERSION}.tar.gz /data/rssadmin
+RUN tar -zxvf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz -C /data/rssadmin
+RUN mv /data/rssadmin/hadoop-${HADOOP_VERSION} /data/rssadmin/hadoop
+RUN rm -rf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz
+COPY hadoopconfig/ /data/rssadmin/hadoop/etc/hadoop
+
+ENV RSS_VERSION ${RSS_VERSION}
+ENV HADOOP_VERSION ${HADOOP_VERSION}
+CMD bash /data/rssadmin/rss/bin/start.sh

Review Comment:
   We need a new line at the end of the file.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] wangao1236 commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
wangao1236 commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938873503


##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz
+/deploy/kubernetes/hadoopconfig/*

Review Comment:
   Because in some cases, we need to replace hadoop default configuration. So I think it is necessary to keep a directory to store the user's own configuration.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939805414


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   > Seems `8-jdk-slim` image is based on Debian stable, which is fine. Can we use `8-jre-slim` here?
   
    What's your reason?



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938982822


##########
.gitignore:
##########
@@ -21,4 +21,5 @@ metastore_db/
 derby.log
 dependency-reduced-pom.xml
 rss-*.tgz
-
+hadoop-*.tar.gz
+/deploy/kubernetes/hadoopconfig/*

Review Comment:
   OK



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] frankliee commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
frankliee commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938892748


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   I suggest to use other general-purpose images, such as alpine or centos. 
   Many companies may have their own JDK choices, so we should treat JDK as 3rd party lib hadoop.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r938921238


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,29 @@
+FROM openjdk:8-jdk-slim

Review Comment:
   It's ok to use openjdk. You can see Spark's Dockerfile https://github.com/apache/spark/blob/b481ed36d129982bdd5aedd0d5864dd954dad006/resource-managers/kubernetes/docker/src/main/dockerfiles/spark/Dockerfile#L19



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#issuecomment-1206488205

   cc @zuston @czy006 Could you help me review this patch?


-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] zuston commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
zuston commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r939596513


##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,46 @@
+#
+# 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 openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \
+      && apt-get clean && rm -rf /var/lib/apt/lists/*
+
+RUN useradd -ms /bin/bash rssadmin
+RUN mkdir -p /data/rssadmin/
+RUN chown -R rssadmin:rssadmin /data
+USER rssadmin
+
+COPY rss-${RSS_VERSION}.tgz /data/rssadmin
+RUN tar -xvf /data/rssadmin/rss-${RSS_VERSION}.tgz -C /data/rssadmin
+RUN mv /data/rssadmin/rss-${RSS_VERSION} /data/rssadmin/rss
+RUN rm -rf /data/rssadmin/rss-${RSS_VERSION}.tgz
+
+COPY start.sh /data/rssadmin/rss/bin
+
+COPY hadoop-${HADOOP_VERSION}.tar.gz /data/rssadmin
+RUN tar -zxvf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz -C /data/rssadmin
+RUN mv /data/rssadmin/hadoop-${HADOOP_VERSION} /data/rssadmin/hadoop
+RUN rm -rf /data/rssadmin/hadoop-${HADOOP_VERSION}.tar.gz
+COPY hadoopconfig/ /data/rssadmin/hadoop/etc/hadoop

Review Comment:
   What files in hadoopconfig folder? core-site/hdfs-site.xml? 



##########
deploy/kubernetes/docker/Dockerfile:
##########
@@ -0,0 +1,46 @@
+#
+# 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 openjdk:8-jdk-slim
+
+ARG HADOOP_VERSION
+ARG RSS_VERSION
+
+RUN apt-get update && apt-get install -y zlib1g zlib1g-dev lzop lsof netcat dnsutils less procps iputils-ping \

Review Comment:
   Do we need to consider kerberos? If yes, we need to setup kerberos client. 
   
   Maybe we shouldn't consider this in early version.



##########
deploy/kubernetes/docker/build.sh:
##########
@@ -0,0 +1,95 @@
+#!/bin/bash
+
+#
+# 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.
+#
+
+function exit_with_usage() {
+  set +x
+  echo "./build.sh - Tool for building docker images of Remote Shuffle Service"
+  echo ""
+  echo "Usage:"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  echo "| ./build.sh [--hadoop-version <hadoop version>] [--registry <registry url>]                           |"
+  echo "+------------------------------------------------------------------------------------------------------+"
+  exit 1
+}
+
+UNKNOWN_REGISTRY="UNKNOWN_REGISTRY"
+REGISTRY=$UNKNOWN_REGISTRY
+
+HADOOP_VERSION=2.8.5
+while (( "$#" )); do
+  case $1 in
+    --registry)
+      REGISTRY="$2"
+      shift
+      ;;
+    --hadoop-version)
+      HADOOP_VERSION="$2"
+      shift
+      ;;
+    --help)
+      exit_with_usage
+      ;;
+    --*)
+      echo "Error: $1 is not supported"
+      exit_with_usage
+      ;;
+    -*)
+      break
+      ;;
+    *)
+      echo "Error: $1 is not supported"
+      exit_with_usage
+      ;;
+  esac
+  shift
+done
+
+if [ "$REGISTRY" == $UNKNOWN_REGISTRY ]; \
+  then echo "please set registry url"; exit; \
+fi
+
+HADOOP_FILE=hadoop-${HADOOP_VERSION}.tar.gz
+HADOOP_URL=https://archive.apache.org/dist/hadoop/core/hadoop-${HADOOP_VERSION}/${HADOOP_FILE}
+echo "HADOOP_URL is $HADOOP_URL"
+if [ ! -e "$HADOOP_FILE" ]; \
+  then wget "$HADOOP_URL"; \
+  else echo "${HADOOP_FILE} has been downloaded"; \
+fi
+
+RSS_DIR=../../..
+cd $RSS_DIR || exit
+RSS_VERSION=$(mvn help:evaluate -Dexpression=project.version 2>/dev/null | grep -v "INFO" | grep -v "WARNING" | tail -n 1)
+RSS_FILE=rss-${RSS_VERSION}.tgz
+if [ ! -e "$RSS_FILE" ]; \
+  then sh build_distribution.sh \
+  else echo "$RSS_FILE has been built"; \
+fi
+cd "$OLDPWD" || exit
+cp "$RSS_DIR/$RSS_FILE" .
+
+IMAGE=$REGISTRY/rss-server:$RSS_VERSION
+
+echo "building image: $IMAGE"
+docker build -t "$IMAGE" \

Review Comment:
   Using LABEL to add more metadata, like build-time/author/branch/commit-id?



##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+#
+# 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.
+#
+
+basedir='/data/rssadmin/rss'
+cd $basedir || exit
+
+coordinator_conf=$basedir'/conf/coordinator.conf'
+echo "coordinator_conf: $coordinator_conf"
+server_conf=$basedir'/conf/server.conf'
+echo "server_conf: $server_conf"
+
+
+if [ "$SERVICE_NAME" == "coordinator" ];then
+
+    bash ${basedir}/bin/start-coordinator.sh &

Review Comment:
    Directly exit when executing startup script failed. 
   
   `bash ${basedir}/bin/start-coordinator.sh || exit 1`



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org


[GitHub] [incubator-uniffle] jerqi commented on a diff in pull request #132: [ISSUE-48][FEATURE] Add Uniffle Dockerfile

Posted by GitBox <gi...@apache.org>.
jerqi commented on code in PR #132:
URL: https://github.com/apache/incubator-uniffle/pull/132#discussion_r940144436


##########
deploy/kubernetes/docker/start.sh:
##########
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+#
+# 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.
+#
+
+basedir='/data/rssadmin/rss'
+cd $basedir || exit
+
+coordinator_conf=$basedir'/conf/coordinator.conf'
+echo "coordinator_conf: $coordinator_conf"
+server_conf=$basedir'/conf/server.conf'
+echo "server_conf: $server_conf"
+
+
+if [ "$SERVICE_NAME" == "coordinator" ];then
+
+    bash ${basedir}/bin/start-coordinator.sh &

Review Comment:
   We kill server or coordinator, the process will not exit immediately sometimes. The process will occupy the port, we should wait for the port for a while.



-- 
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: issues-unsubscribe@uniffle.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org