You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@linkis.apache.org by pe...@apache.org on 2023/06/07 03:57:54 UTC

[linkis] branch dev-1.4.0 updated: Support integtation test git action (#4601)

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

peacewong pushed a commit to branch dev-1.4.0
in repository https://gitbox.apache.org/repos/asf/linkis.git


The following commit(s) were added to refs/heads/dev-1.4.0 by this push:
     new 9bb6cd8b5 Support integtation test git action (#4601)
9bb6cd8b5 is described below

commit 9bb6cd8b5192c0f9481559d9fe7a4de554b10a2d
Author: Casion <ca...@gmail.com>
AuthorDate: Wed Jun 7 11:57:46 2023 +0800

    Support integtation test git action (#4601)
    
    * support integtation test git action
    
    * support integtation test git action
    
    * support integtation test git action
    
    * add rat check ignore of .gitmodules file
    
    * add description
---
 .github/actions/chart-testing-action               |   1 +
 .github/actions/kind-action                        |   1 +
 .github/workflows/integration-test.yml             | 188 +++++++++++++++++++++
 .github/workflows/publish-docker.yaml              |   7 +-
 .gitmodules                                        |   6 +
 README.md                                          |   2 +-
 README_CN.md                                       |   2 +-
 linkis-dist/bin/install-linkis-to-kubernetes.sh    |   6 +-
 linkis-dist/docker/scripts/entry-point-ldh.sh      |   5 +-
 linkis-dist/helm/README.md                         |   6 +-
 linkis-dist/helm/README_CN.md                      |   6 +-
 .../linkis/templates/configmap-linkis-config.yaml  |  41 ++++-
 .../templates/linkis-cg-engineconnmanager.yaml     |   2 +-
 .../linkis/templates/linkis-cg-entrance.yaml       |   2 +-
 .../linkis/templates/linkis-cg-linkismanager.yaml  |   2 +-
 .../charts/linkis/templates/linkis-mg-eureka.yaml  |   2 +-
 .../charts/linkis/templates/linkis-mg-gateway.yaml |   2 +-
 .../linkis/templates/linkis-ps-publicservice.yaml  |   2 +-
 .../helm/scripts/install-charts-with-ldh.sh        |   4 +-
 linkis-dist/helm/scripts/install-ldh.sh            |   4 +-
 linkis-dist/helm/scripts/install-linkis.sh         |   6 +-
 linkis-dist/helm/scripts/install-mysql.sh          |   3 +-
 .../package/conf/linkis-cli/linkis-cli.properties  |   4 +-
 pom.xml                                            |   4 +-
 24 files changed, 274 insertions(+), 34 deletions(-)

diff --git a/.github/actions/chart-testing-action b/.github/actions/chart-testing-action
new file mode 160000
index 000000000..2fffad315
--- /dev/null
+++ b/.github/actions/chart-testing-action
@@ -0,0 +1 @@
+Subproject commit 2fffad315319f278a64ba2e94505768bd9e2a633
diff --git a/.github/actions/kind-action b/.github/actions/kind-action
new file mode 160000
index 000000000..fa81e57ad
--- /dev/null
+++ b/.github/actions/kind-action
@@ -0,0 +1 @@
+Subproject commit fa81e57adff234b2908110485695db0f181f3c67
diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml
new file mode 100644
index 000000000..1fb0b6605
--- /dev/null
+++ b/.github/workflows/integration-test.yml
@@ -0,0 +1,188 @@
+#
+# 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: Integration Test
+
+on:
+  push:
+    branches:
+      - dev-1.4.0
+  pull_request:
+    branches:
+      - dev-1.4.0
+
+#concurrency:
+#  group: test-${{ github.head_ref || github.run_id }}
+#  cancel-in-progress: true
+
+env:
+  KIND_CONFIG_PATH: './linkis-dist/helm/scripts/resources/kind-cluster.yaml'
+  KIND_CLUSTER_NAME: 'test-helm'
+  MAVEN_OPTS: -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.http.retryHandler.class=standard -Dmaven.wagon.http.retryHandler.count=3 -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
+jobs:
+  integration-test:
+    runs-on: ubuntu-latest
+    strategy:
+      matrix:
+        node-version: [16.0.0]
+        kubernetes-version:
+          #          - 'kindest/node:v1.21.10'
+          - 'kindest/node:v1.23.4'
+    timeout-minutes: 90
+    env:
+      TAG: ${{ github.sha }}
+      SKIP_TEST: true
+      HUB: ghcr.io/apache/linkis
+      LINKIS_VERSION: 1.4.0-SNAPSHOT
+    steps:
+      - name: Free up disk space
+        run: |
+          # https://github.com/actions/runner-images/issues/2840#issuecomment-790492173
+          # du -sh /*        2> /dev/null | sort -rh  2> /dev/null | head
+          # du -h -d2 /usr   2> /dev/null | sort -rh  2> /dev/null | head
+          echo $JAVA_HOME
+          echo "Check free disk space before cleanup."
+          df -h
+          echo "Removing non-essential tools and libraries."
+          sudo rm -rf "$AGENT_TOOLSDIRECTORY"
+          sudo rm -rf /opt/ghc
+          sudo rm -rf /usr/share/dotnet
+          sudo rm -rf /usr/local/share/boost
+          # delete libraries for Android (12G), PowerShell (1.3G), Swift (1.7G)
+          sudo rm -rf /usr/local/lib/android
+          sudo rm -rf /usr/local/share/powershell
+          sudo rm -rf /usr/share/swift
+          echo "Check free disk space after cleanup."
+          df -h
+          echo $JAVA_HOME
+      - name: Prune docker images
+        run: |
+          echo "Pruning docker images on GH action runner node"
+          docker image prune -a -f
+          docker system df
+          df -h
+
+      - name: Checkout
+        uses: actions/checkout@v2
+        with:
+          fetch-depth: 0
+          submodules: true
+      - name: Set up JDK 8
+        uses: actions/setup-java@v2
+        with:
+          distribution: 'adopt'
+          java-version: 8
+      - name: Cache local Maven repository
+        uses: actions/cache@v2
+        with:
+          path: ~/.m2/repository
+          key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
+          restore-keys: |
+            ${{ runner.os }}-maven-
+      - name: Use Node.js ${{ matrix.node-version }}
+        uses: actions/setup-node@v2
+        with:
+          node-version: ${{ matrix.node-version }}
+      - name: Set up Docker Buildx
+        uses: docker/setup-buildx-action@v1
+
+      - name: Build frontend by node.js
+        run: |
+          cd linkis-web
+          sed -i "/VUE_APP_MN_CONFIG_PREFIX/d" .env
+          npm install
+          npm run build
+
+      - name: Build backend by maven
+        run: |
+          ./mvnw install -Pdocker -Dmysql.connector.scope=compile -Dmaven.javadoc.skip=true -Dmaven.test.skip=true -Dlinkis.build.web=true -Dlinkis.build.ldh=true
+
+      - name: Set up chart-testing
+        uses: ./.github/actions/chart-testing-action
+
+
+      - name: Create Kind cluster
+        uses: ./.github/actions/kind-action
+        with:
+          config: ${{ env.KIND_CONFIG_PATH }}
+          node_image: ${{ matrix.kubernetes-version }}
+          cluster_name: ${{ env.KIND_CLUSTER_NAME }}
+
+      - name: Start Linkis Service
+        run: |
+          docker tag linkis:${{ env.LINKIS_VERSION }}     linkis:dev
+          docker tag linkis-web:${{ env.LINKIS_VERSION }} linkis-web:dev
+          docker tag linkis-ldh:${{ env.LINKIS_VERSION }} linkis-ldh:dev
+
+          # for debug Download the image directly first, then adjust it to active build
+          #ROOT_DIR=./linkis-dist/
+          #MIRRORS="ghcr.io"
+          #TAG="dev"
+          #docker pull ${MIRRORS}/apache/linkis/linkis-ldh:${TAG}
+          #docker pull ${MIRRORS}/apache/linkis/linkis:${TAG}
+          #docker pull ${MIRRORS}/apache/linkis/linkis-web:${TAG}
+          #docker tag  ${MIRRORS}/apache/linkis/linkis:${TAG} linkis:dev
+          #docker tag  ${MIRRORS}/apache/linkis/linkis-web:${TAG} linkis-web:dev
+          #docker tag  ${MIRRORS}/apache/linkis/linkis-ldh:${TAG} linkis-ldh:dev
+
+
+          #show image list
+          docker image ls
+          bash ./linkis-dist/helm/scripts/install-mysql.sh  false\
+              && bash ./linkis-dist/helm/scripts/install-ldh.sh true \
+              && bash ./linkis-dist/helm/scripts/install-charts-with-ldh.sh linkis linkis-demo true
+          n=0
+          sleep 60
+          while (($n<10))
+          do
+            kubectl get pods -A
+            n=$((n+1))
+            sleep 20
+          done
+
+          #show linkis pod logs
+          #POD_NAME=`kubectl get pods -n linkis -l app.kubernetes.io/instance=linkis-demo-cg-linkismanager -o jsonpath='{.items[0].metadata.name}'`
+          #kubectl logs -n linkis  ${POD_NAME} -f --tail=10000
+          #POD_NAME=`kubectl get pods -n linkis -l app.kubernetes.io/instance=linkis-demo-cg-engineconnmanager -o jsonpath='{.items[0].metadata.name}'`
+          #kubectl logs -n linkis  ${POD_NAME} -f --tail=10000
+        shell: bash
+
+      - name: Linkis-Cli Test
+        run: |
+          # Enable port-forward
+          bash ./linkis-dist/helm/scripts/remote-proxy.sh start
+          # Show port-forward list
+          bash ./linkis-dist/helm/scripts/remote-proxy.sh list
+          # Check if the web service is available
+          curl http://127.0.0.1:8088/indexhtml
+
+          # Execute test by linkis-cli
+          POD_NAME=`kubectl get pods -n linkis -l app.kubernetes.io/instance=linkis-demo-mg-gateway -o jsonpath='{.items[0].metadata.name}'`
+          kubectl exec -it -n linkis  ${POD_NAME} -- bash -c " \
+          sh /opt/linkis/bin/linkis-cli -engineType shell-1 -codeType shell -code \"pwd\" ";
+
+          kubectl exec -it -n linkis  ${POD_NAME} -- bash -c " \
+          sh /opt/linkis/bin/linkis-cli -engineType python-python2 -codeType python -code   'print(\"hello\")' "
+
+          #todo
+          #kubectl exec -it -n linkis  ${POD_NAME} -- bash -c " \
+          #sh /opt/linkis/bin/linkis-cli -engineType hive-3.1.3 -codeType hql -code   'show databases' "
+
+          #kubectl exec -it -n linkis  ${POD_NAME} -- bash -c " \
+          #sh /opt/linkis/bin/linkis-cli -engineType spark-3.2.1 -codeType sql -code   'show databases' "
+
+        shell: bash
\ No newline at end of file
diff --git a/.github/workflows/publish-docker.yaml b/.github/workflows/publish-docker.yaml
index 11c8fcc6c..fdd998b1e 100644
--- a/.github/workflows/publish-docker.yaml
+++ b/.github/workflows/publish-docker.yaml
@@ -16,10 +16,13 @@
 #
 
 name: Publish Docker
-on: 
+on:
   push:
     branches:
       - dev-1.4.0
+env:
+  MAVEN_OPTS: -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.http.retryHandler.class=standard -Dmaven.wagon.http.retryHandler.count=3 -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
+
 jobs:
   publish-docker:
     runs-on: ubuntu-latest
@@ -72,7 +75,7 @@ jobs:
         username: ${{ github.actor }}
         password: ${{ secrets.GITHUB_TOKEN }}
     - name: Push Docker Image
-      env: 
+      env:
         DOCKER_VERSION: ${{ github.ref_name }}-${{ github.sha }}
       run: |
         docker images
diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 000000000..82ecf9692
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,6 @@
+[submodule ".github/actions/chart-testing-action"]
+	path = .github/actions/chart-testing-action
+	url = git@github.com:helm/chart-testing-action.git
+[submodule ".github/actions/kind-action"]
+	path = .github/actions/kind-action
+	url = git@github.com:helm/kind-action.git
diff --git a/README.md b/README.md
index c6dea6c11..42a8a4f79 100644
--- a/README.md
+++ b/README.md
@@ -154,7 +154,7 @@ linkis image by yourself, the image created by this tool will be tagged as `link
 
 ```shell
 $> LINKIS_IMAGE=linkis:1.3.1 
-$> ./linkis-dist/docker/scripts/make-linikis-image-with-mysql-jdbc.sh
+$> ./linkis-dist/docker/scripts/make-linkis-image-with-mysql-jdbc.sh
 ```
 
 
diff --git a/README_CN.md b/README_CN.md
index 3a3aa6708..aaba2e027 100644
--- a/README_CN.md
+++ b/README_CN.md
@@ -143,7 +143,7 @@ npm run build
 
 ```shell
 $> LINKIS_IMAGE=linkis:1.3.1 
-$> ./linkis-dist/docker/scripts/make-linikis-image-with-mysql-jdbc.sh
+$> ./linkis-dist/docker/scripts/make-linkis-image-with-mysql-jdbc.sh
 ```
 
 请参考[快速安装部署 ](https://linkis.apache.org/zh-CN/docs/latest/deployment/deploy-quick/) 来部署 Linkis
diff --git a/linkis-dist/bin/install-linkis-to-kubernetes.sh b/linkis-dist/bin/install-linkis-to-kubernetes.sh
index 1bdb1e36e..44e84e989 100644
--- a/linkis-dist/bin/install-linkis-to-kubernetes.sh
+++ b/linkis-dist/bin/install-linkis-to-kubernetes.sh
@@ -83,8 +83,8 @@ tag(){
     fi
 }
 #create an image to carry mysql
-make_linikis_image_with_mysql_jdbc(){
-    ${ROOT_DIR}/docker/scripts/make-linikis-image-with-mysql-jdbc.sh
+make_linkis_image_with_mysql_jdbc(){
+    ${ROOT_DIR}/docker/scripts/make-linkis-image-with-mysql-jdbc.sh
     docker tag linkis:with-jdbc linkis:dev
 }
 #creating a kind cluster
@@ -117,7 +117,7 @@ display_pods(){
 install(){
     if [ $USING_KIND = true ]; then
       tag
-      make_linikis_image_with_mysql_jdbc
+      make_linkis_image_with_mysql_jdbc
       create_kind_cluster
     fi
     install_mysql
diff --git a/linkis-dist/docker/scripts/entry-point-ldh.sh b/linkis-dist/docker/scripts/entry-point-ldh.sh
index 6afa22890..7fac1b181 100644
--- a/linkis-dist/docker/scripts/entry-point-ldh.sh
+++ b/linkis-dist/docker/scripts/entry-point-ldh.sh
@@ -22,8 +22,9 @@ WORK_DIR=`cd $(dirname $0); pwd -P`
 hdfs namenode -format
 /opt/ldh/current/hadoop/sbin/hadoop-daemon.sh start namenode
 /opt/ldh/current/hadoop/sbin/hadoop-daemon.sh start datanode
-/opt/ldh/current/hadoop/sbin/yarn-daemon.sh start resourcemanager
-/opt/ldh/current/hadoop/sbin/yarn-daemon.sh start nodemanager
+# hadoop2.7 is yarn-daemon.sh
+/opt/ldh/current/hadoop/bin/yarn --daemon  start resourcemanager
+/opt/ldh/current/hadoop/bin/yarn --daemon start nodemanager
 
 # - init dirs on hdfs
 hdfs dfs -mkdir -p /tmp
diff --git a/linkis-dist/helm/README.md b/linkis-dist/helm/README.md
index 81e076cb9..2dfaec11b 100644
--- a/linkis-dist/helm/README.md
+++ b/linkis-dist/helm/README.md
@@ -255,14 +255,14 @@ No rows affected (1.306 seconds)
 No rows affected (0.046 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> create table t1 (id int, data string);
 No rows affected (0.709 seconds)
-0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> insert into t1 values(1, 'linikis demo');
+0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> insert into t1 values(1, 'linkis demo');
 WARNING: Hive-on-MR is deprecated in Hive 2 and may not be available in the future versions. Consider using a different execution engine (i.e. spark, tez) or using Hive 1.X releases.
 No rows affected (5.491 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> select * from t1;
 +--------+---------------+
 | t1.id  |    t1.data    |
 +--------+---------------+
-| 1      | linikis demo  |
+| 1      | linkis demo  |
 +--------+---------------+
 1 row selected (0.39 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> !q
@@ -288,7 +288,7 @@ Time taken: 0.074 seconds
 22/07/31 02:58:02 INFO thriftserver.SparkSQLCLIDriver: Time taken: 0.074 seconds
 spark-sql> select * from t1;
 ...
-1       linikis demo
+1       linkis demo
 2       linkis demo spark sql
 Time taken: 3.352 seconds, Fetched 2 row(s)
 spark-sql> quit;
diff --git a/linkis-dist/helm/README_CN.md b/linkis-dist/helm/README_CN.md
index bbac5c2b8..743410125 100644
--- a/linkis-dist/helm/README_CN.md
+++ b/linkis-dist/helm/README_CN.md
@@ -246,14 +246,14 @@ No rows affected (1.306 seconds)
 No rows affected (0.046 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> create table t1 (id int, data string);
 No rows affected (0.709 seconds)
-0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> insert into t1 values(1, 'linikis demo');
+0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> insert into t1 values(1, 'linkis demo');
 WARNING: Hive-on-MR is deprecated in Hive 2 and may not be available in the future versions. Consider using a different execution engine (i.e. spark, tez) or using Hive 1.X releases.
 No rows affected (5.491 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> select * from t1;
 +--------+---------------+
 | t1.id  |    t1.data    |
 +--------+---------------+
-| 1      | linikis demo  |
+| 1      | linkis demo  |
 +--------+---------------+
 1 row selected (0.39 seconds)
 0: jdbc:hive2://ldh.ldh.svc.cluster.local:100> !q
@@ -279,7 +279,7 @@ Time taken: 0.074 seconds
 22/07/31 02:58:02 INFO thriftserver.SparkSQLCLIDriver: Time taken: 0.074 seconds
 spark-sql> select * from t1;
 ...
-1       linikis demo
+1       linkis demo
 2       linkis demo spark sql
 Time taken: 3.352 seconds, Fetched 2 row(s)
 spark-sql> quit;
diff --git a/linkis-dist/helm/charts/linkis/templates/configmap-linkis-config.yaml b/linkis-dist/helm/charts/linkis/templates/configmap-linkis-config.yaml
index 7a7092ef2..e6f419744 100644
--- a/linkis-dist/helm/charts/linkis/templates/configmap-linkis-config.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/configmap-linkis-config.yaml
@@ -80,9 +80,13 @@ data:
     eureka:
       instance:
         prefer-ip-address: true
+        instance-id: ${spring.cloud.client.ip-address}:${spring.application.name}:${server.port}
+        lease-renewal-interval-in-seconds: 4
+        lease-expiration-duration-in-seconds: 12
       client:
         serviceUrl:
           defaultZone: {{- include "linkis.registration.url" . | quote | indent 1 }}
+        registry-fetch-interval-seconds: 8
     management:
       endpoints:
         web:
@@ -118,8 +122,8 @@ data:
       port: {{ .Values.mgEureka.port }}
     eureka:
       instance:
-        hostname: localhost
         preferIpAddress: true
+        hostname: ${spring.cloud.client.ip-address}
       client:
         register-with-eureka: false
         fetch-registry: false
@@ -132,6 +136,35 @@ data:
         eviction-interval-timer-in-ms: 5000
         response-cache-update-interval-ms: 3000
 
+  application-engineconn.yml: |
+    spring:
+      application:
+        name: linkis-cg-engineconn
+      servlet:
+        multipart:
+          max-file-size: 500MB
+          max-request-size: 500MB
+          file-size-threshold: 50MB
+    eureka:
+      instance:
+        prefer-ip-address: true
+        instance-id: ${spring.cloud.client.ip-address}:${spring.application.name}:${server.port}
+        lease-renewal-interval-in-seconds: 4
+        lease-expiration-duration-in-seconds: 12
+      client:
+        serviceUrl:
+           defaultZone: {{- include "linkis.registration.url" . | quote | indent 1 }}
+        registry-fetch-interval-seconds: 8
+        initial-instance-info-replication-interval-seconds: 10
+    management:
+      endpoints:
+        web:
+          exposure:
+            include: refresh,info,health,metrics
+
+    logging:
+      config: classpath:log4j2.xml
+
   linkis-cli.properties: |
     #wds.linkis.client.common.creator=LINKISCLI
     wds.linkis.client.common.gatewayUrl={{- include "linkis.gateway.url" . }}
@@ -148,7 +181,11 @@ data:
     wds.linkis.server.version=v1
     ##spring conf
     wds.linkis.gateway.url={{- include "linkis.gateway.url" . }}
-    wds.linkis.eureka.defaultZone={{- include "linkis.registration.url" . }}
+
+    wds.linkis.multiple.yarn.cluster=false
+    linkis.discovery.prefer-ip-address=true
+    linkis.discovery.server-address={{- include "linkis.registration.url" . }}
+
     ##mybatis
     wds.linkis.server.mybatis.datasource.url={{- include "linkis.datasource.url" . }}
     wds.linkis.server.mybatis.datasource.username={{ .Values.linkis.datasource.username }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-cg-engineconnmanager.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-cg-engineconnmanager.yaml
index b87d0eb2e..6e2de354c 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-cg-engineconnmanager.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-cg-engineconnmanager.yaml
@@ -166,7 +166,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-engineconnmanager
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-engineconnmanager
           ports:
             - name: "http"
               containerPort: {{ .Values.cgEngineConnManager.port }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-cg-entrance.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-cg-entrance.yaml
index 426fb105d..db523a07b 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-cg-entrance.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-cg-entrance.yaml
@@ -130,7 +130,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-entrance
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-entrance
           ports:
             - name: "http"
               containerPort: {{ .Values.cgEntrance.port }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-cg-linkismanager.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-cg-linkismanager.yaml
index 2167ae897..905239d63 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-cg-linkismanager.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-cg-linkismanager.yaml
@@ -123,7 +123,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-linkismanager
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start cg-linkismanager
           ports:
             - name: "http"
               containerPort: {{ .Values.cgLinkisManager.port }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-mg-eureka.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-mg-eureka.yaml
index 5fe82a189..0fe3753df 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-mg-eureka.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-mg-eureka.yaml
@@ -120,7 +120,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib  {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start mg-eureka
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib  {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start mg-eureka
           ports:
             - name: "http"
               containerPort: {{ .Values.mgEureka.port }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-mg-gateway.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-mg-gateway.yaml
index 06d3a8c1f..0840abcb6 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-mg-gateway.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-mg-gateway.yaml
@@ -123,7 +123,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start mg-gateway
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start mg-gateway
           ports:
             - name: "http"
               containerPort: {{ .Values.mgGateway.port }}
diff --git a/linkis-dist/helm/charts/linkis/templates/linkis-ps-publicservice.yaml b/linkis-dist/helm/charts/linkis/templates/linkis-ps-publicservice.yaml
index 3b3e87c3e..4a25c26f6 100644
--- a/linkis-dist/helm/charts/linkis/templates/linkis-ps-publicservice.yaml
+++ b/linkis-dist/helm/charts/linkis/templates/linkis-ps-publicservice.yaml
@@ -135,7 +135,7 @@ spec:
             - /bin/bash
             - -ecx
             - >-
-              RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start ps-publicservice
+              EUREKA_PREFER_IP=true RUN_IN_FOREGROUND=true LINKIS_EXTENDED_LIB={{.Values.linkis.locations.commonDir}}/extendlib {{ .Values.linkis.locations.homeDir }}/sbin/linkis-daemon.sh start ps-publicservice
           ports:
             - name: "http"
               containerPort: {{ .Values.psPublicService.port }}
diff --git a/linkis-dist/helm/scripts/install-charts-with-ldh.sh b/linkis-dist/helm/scripts/install-charts-with-ldh.sh
index b2757bcc0..f119cbb8f 100755
--- a/linkis-dist/helm/scripts/install-charts-with-ldh.sh
+++ b/linkis-dist/helm/scripts/install-charts-with-ldh.sh
@@ -22,7 +22,7 @@ WORK_DIR=`cd $(dirname $0); pwd -P`
 KUBE_NAMESPACE=${1:-linkis}
 HELM_RELEASE_NAME=${2:-linkis-demo}
 USING_KIND=${3:-false}
-
-sh ${WORK_DIR}/install-linkis.sh ${KUBE_NAMESPACE} ${HELM_RELEASE_NAME} false ${USING_KIND}
+# use bash fix "[[ : not found"
+bash ${WORK_DIR}/install-linkis.sh ${KUBE_NAMESPACE} ${HELM_RELEASE_NAME} false ${USING_KIND}
 
 kubectl apply -n ${KUBE_NAMESPACE} -f ${RESOURCE_DIR}/ldh/configmaps
diff --git a/linkis-dist/helm/scripts/install-ldh.sh b/linkis-dist/helm/scripts/install-ldh.sh
index 7be4d3486..3ada87bef 100755
--- a/linkis-dist/helm/scripts/install-ldh.sh
+++ b/linkis-dist/helm/scripts/install-ldh.sh
@@ -26,7 +26,7 @@ LDH_VERSION=${LDH_VERSION-${LINKIS_IMAGE_TAG}}
 echo "# LDH version: ${LINKIS_IMAGE_TAG}"
 
 # load image
-if [ "X${USING_KIND}" == "Xtrue" ]; then
+if [[ "X${USING_KIND}" == "Xtrue" ]]; then
   echo "# Loading LDH image ..."
   kind load docker-image linkis-ldh:${LINKIS_IMAGE_TAG} --name ${KIND_CLUSTER_NAME}
 fi
@@ -36,7 +36,7 @@ echo "# Deploying LDH ..."
 set +e
 x=`kubectl get ns ldh 2> /dev/null`
 set -e
-if [ "X${x}" == "X" ]; then
+if [[ "X${x}" == "X" ]]; then
   kubectl create ns ldh
 fi
 kubectl apply -n ldh -f ${RESOURCE_DIR}/ldh/configmaps
diff --git a/linkis-dist/helm/scripts/install-linkis.sh b/linkis-dist/helm/scripts/install-linkis.sh
index 2abf12a0d..c474f0276 100755
--- a/linkis-dist/helm/scripts/install-linkis.sh
+++ b/linkis-dist/helm/scripts/install-linkis.sh
@@ -24,16 +24,16 @@ HELM_RELEASE_NAME=${2:-linkis-demo}
 LOCAL_MODE=${3:-true}
 USING_KIND=${4:-false}
 
-if [ "X${HELM_DEBUG}" == "Xtrue" ]; then
+if [[ "X${HELM_DEBUG}" == "Xtrue" ]]; then
   # template helm charts
   helm template --namespace ${KUBE_NAMESPACE} -f ${LINKIS_CHART_DIR}/values.yaml ${HELM_RELEASE_NAME} ${LINKIS_CHART_DIR}
 else
   # create hadoop configs
-  if [ "X${WITH_LDH}" == "Xtrue" ]; then
+  if [[ "X${WITH_LDH}" == "Xtrue" ]]; then
     kubectl apply -n ${KUBE_NAMESPACE} -f ${RESOURCE_DIR}/ldh/configmaps
   fi
   # load image
-  if [ "X${USING_KIND}" == "Xtrue" ]; then
+  if [[ "X${USING_KIND}" == "Xtrue" ]]; then
     echo "# Loading Linkis image ..."
     kind load docker-image linkis:${LINKIS_IMAGE_TAG} --name ${KIND_CLUSTER_NAME}
     kind load docker-image linkis-web:${LINKIS_IMAGE_TAG} --name ${KIND_CLUSTER_NAME}
diff --git a/linkis-dist/helm/scripts/install-mysql.sh b/linkis-dist/helm/scripts/install-mysql.sh
index 07e35678b..e73586ab1 100755
--- a/linkis-dist/helm/scripts/install-mysql.sh
+++ b/linkis-dist/helm/scripts/install-mysql.sh
@@ -19,12 +19,13 @@ WORK_DIR=`cd $(dirname $0); pwd -P`
 
 . ${WORK_DIR}/common.sh
 
+USING_KIND=${1:-false}
 MYSQL_VERSION=${MYSQL_VERSION:-5.7}
 
 set -e
 
 # load image
-if [ "X${USING_KIND}" == "Xtrue" ]; then
+if [[ "X${USING_KIND}" == "Xtrue" ]]; then
   echo "# Loading MySQL image ..."
   kind load docker-image mysql:${MYSQL_VERSION} --name ${KIND_CLUSTER_NAME}
 fi
diff --git a/linkis-dist/package/conf/linkis-cli/linkis-cli.properties b/linkis-dist/package/conf/linkis-cli/linkis-cli.properties
index c57fea9e2..4847d443e 100644
--- a/linkis-dist/package/conf/linkis-cli/linkis-cli.properties
+++ b/linkis-dist/package/conf/linkis-cli/linkis-cli.properties
@@ -18,5 +18,5 @@ wds.linkis.client.common.gatewayUrl=http://127.0.0.1:9001
 wds.linkis.client.common.authStrategy=token
 wds.linkis.client.common.tokenKey=Validation-Code
 wds.linkis.client.common.tokenValue=BML-AUTH
-#wds.linkis.client.noncustomizable.enable.user.specification=true
-#wds.linkis.client.noncustomizable.enable.proxy.user=true
\ No newline at end of file
+wds.linkis.client.noncustomizable.enable.user.specification=true
+wds.linkis.client.noncustomizable.enable.proxy.user=true
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 5f3693198..4f89073ae 100644
--- a/pom.xml
+++ b/pom.xml
@@ -159,6 +159,7 @@
     <jedis.version>3.9.0</jedis.version>
     <mybatis-plus.version>3.4.3.4</mybatis-plus.version>
     <mysql.connector.version>8.0.28</mysql.connector.version>
+    <mysql.connector.scope>test</mysql.connector.scope>
     <postgresql.connector.version>42.2.20</postgresql.connector.version>
     <druid.version>1.2.16</druid.version>
 
@@ -350,7 +351,7 @@
         <groupId>mysql</groupId>
         <artifactId>mysql-connector-java</artifactId>
         <version>${mysql.connector.version}</version>
-        <scope>test</scope>
+        <scope>${mysql.connector.scope}</scope>
       </dependency>
 
       <dependency>
@@ -1562,6 +1563,7 @@
               <exclude>CONTRIBUTING.md</exclude>
               <exclude>CONTRIBUTING_CN.md</exclude>
               <exclude>README.md</exclude>
+              <exclude>.gitmodules</exclude>
               <exclude>**/META-INF/**</exclude>
               <exclude>.github/**</exclude>
               <exclude>compiler/**</exclude>


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@linkis.apache.org
For additional commands, e-mail: commits-help@linkis.apache.org