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

benjobs pushed a commit to branch dev-2.1.4
in repository https://gitbox.apache.org/repos/asf/incubator-streampark.git


The following commit(s) were added to refs/heads/dev-2.1.4 by this push:
     new 9cbf8bd8f [Improve] docker-compose.yaml improvement
9cbf8bd8f is described below

commit 9cbf8bd8fffdad6d4c4de391dfb3127246951e5f
Author: benjobs <[email protected]>
AuthorDate: Sat Apr 6 23:17:16 2024 +0800

    [Improve] docker-compose.yaml improvement
---
 docker/.env                | 15 +-------
 docker/config.yaml         | 91 ++++++++++++++++++++++++++++++++++++++++++++++
 docker/docker-compose.yaml |  3 +-
 3 files changed, 95 insertions(+), 14 deletions(-)

diff --git a/docker/.env b/docker/.env
index 800c55d9c..4a1f5de11 100644
--- a/docker/.env
+++ b/docker/.env
@@ -15,19 +15,8 @@
 # specific language governing permissions and limitations
 # under the License.
 #
-
-TZ=Asia/Shanghai
-
-SPRING_PROFILES_ACTIVE=h2 #mysql, pgsql
-# If use mysql or pgsql, please set the following parameters
-#SPRING_DATASOURCE_URL=jdbc:mysql://localhost:3306/streampark?useSSL=false&useUnicode=true&characterEncoding=UTF-8&allowPublicKeyRetrieval=false&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8
-#SPRING_DATASOURCE_URL=jdbc:postgresql://localhost:5432/streampark?stringtype=unspecified
-#SPRING_DATASOURCE_USERNAME=root
-#SPRING_DATASOURCE_PASSWORD=streampark
-
+SERVER_PORT=10000
 FLINK=flink1.14.5
 FLINK_IMAGE=flink:1.14.5-scala_2.12
-
+TZ=Asia/Shanghai
 RUN_COMMAND='/bin/sh -c "wget -P lib 
https://repo1.maven.org/maven2/com/mysql/mysql-connector-j/8.0.31/mysql-connector-j-8.0.31.jar
 && bash bin/streampark.sh start_docker "'
-
-JOB_MANAGER_RPC_ADDRESS=flink-jobmanager
diff --git a/docker/config.yaml b/docker/config.yaml
new file mode 100644
index 000000000..b2e0c385c
--- /dev/null
+++ b/docker/config.yaml
@@ -0,0 +1,91 @@
+#
+# 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.
+#
+
+logging:
+  level:
+    root: info
+
+server:
+  port: ${SERVER_PORT}
+  session:
+    # The user's login session has a validity period. If it exceeds this time, 
the user will be automatically logout
+    # unit: s|m|h|d, s: second, m:minute, h:hour, d: day
+    ttl: 2h # unit[s|m|h|d], e.g: 24h, 2d....
+  undertow: # see: 
https://github.com/undertow-io/undertow/blob/master/core/src/main/java/io/undertow/Undertow.java
+    buffer-size: 1024
+    direct-buffers: true
+    threads:
+      io: 16
+      worker: 256
+
+# system database, default h2, mysql|pgsql|h2
+datasource:
+  dialect: h2  #h2, pgsql
+  # if datasource.dialect is mysql or pgsql, you need to configure the 
following connection information
+  # mysql/postgresql connect access user
+  username:
+  # mysql/postgresql connect access password
+  password:
+  # mysql/postgresql connection address
+  # mysql jdbc url example: datasource.url: 
jdbc:mysql://localhost:3306/streampark?useUnicode=true&characterEncoding=UTF-8&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=GMT%2B8
+  # postgresql jdbc url example: 
jdbc:postgresql://localhost:5432/streampark?stringtype=unspecified
+  url:
+
+streampark:
+  workspace:
+    # Local workspace, storage of clone projects and compiled projects,Do not 
set under $APP_HOME. Set it to a directory outside of $APP_HOME.
+    local: /tmp/streampark
+    # The root hdfs path of the jars, Same as yarn.provided.lib.dirs for flink 
on yarn-application
+    # and Same as --jars for spark on yarn
+    remote: hdfs:///streampark/
+  proxy:
+    # lark proxy address, default https://open.feishu.cn
+    lark-url:
+    # hadoop yarn proxy path, e.g: knox process address 
https://streampark.com:8443/proxy/yarn
+    yarn-url:
+  yarn:
+    # flink on yarn or spark on yarn, monitoring job status from yarn, it is 
necessary to set hadoop.http.authentication.type
+    http-auth: 'simple'  # default simple, or kerberos
+  # flink on yarn or spark on yarn, HADOOP_USER_NAME
+  hadoop-user-name: hdfs
+  # flink on k8s ingress setting, If an ingress controller is specified in the 
configuration, the ingress class
+  #  kubernetes.io/ingress.class must be specified when creating the ingress, 
since there are often
+  #  multiple ingress controllers in a production environment.
+  flink-k8s.ingress.class: nginx
+
+# flink on yarn or spark on yarn, when the hadoop cluster enable kerberos 
authentication,
+# it is necessary to set up Kerberos authentication related parameters.
+security:
+  kerberos:
+    login:
+      debug: false
+      enable: false
+      keytab:
+      krb5:
+      principal:
+    ttl: 2h # unit [s|m|h|d]
+
+# sign streampark with ldap.
+ldap:
+  base-dn: dc=streampark,dc=com  # Login Account
+  enable: false  # ldap enabled'
+  username: cn=Manager,dc=streampark,dc=com
+  password: streampark
+  urls: ldap://99.99.99.99:389 #AD server IP, default port 389
+  user:
+    email-attribute: mail
+    identity-attribute: uid
diff --git a/docker/docker-compose.yaml b/docker/docker-compose.yaml
index 795f00057..97e1cba09 100644
--- a/docker/docker-compose.yaml
+++ b/docker/docker-compose.yaml
@@ -20,9 +20,10 @@ services:
     image: apache/streampark:latest
     command: ${RUN_COMMAND}
     ports:
-      - 10000:10000
+      - ${SERVER_PORT}:${SERVER_PORT}
     env_file: .env
     volumes:
+      - ./config.yaml:/streampark/conf/config.yaml
       - flink:/streampark/flink/${FLINK}
       - /var/run/docker.sock:/var/run/docker.sock
       - /etc/hosts:/etc/hosts:ro

Reply via email to