From a238e04cd229e71bafd381da57d0b7830b0aed04 Mon Sep 17 00:00:00 2001 From: Pil0tXia Date: Mon, 8 Apr 2024 17:58:32 +0800 Subject: [PATCH 1/3] Update auto deploy branch from `dev` to `main` --- deployment/auto-deploy-eventmesh-dashboard.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/deployment/auto-deploy-eventmesh-dashboard.sh b/deployment/auto-deploy-eventmesh-dashboard.sh index 8af598d6..33c26aaa 100644 --- a/deployment/auto-deploy-eventmesh-dashboard.sh +++ b/deployment/auto-deploy-eventmesh-dashboard.sh @@ -45,13 +45,13 @@ is_process_running() { # Update the git repository cd $REPO_PATH -git fetch origin dev +git fetch origin main LOCAL=$(git rev-parse @) -REMOTE=$(git rev-parse origin/dev) +REMOTE=$(git rev-parse origin/main) if [ $LOCAL != $REMOTE ]; then - # If the remote dev branch is newer than the local one, update the local dev branch code - git pull origin dev + # If the remote branch is newer than the local one, update the local branch code + git pull origin main # Log the event echo "$(date +"%Y-%m-%d %H:%M:%S") - change detected." >> $AUTO_DEPLOY_LOG @@ -76,7 +76,7 @@ if [ $LOCAL != $REMOTE ]; then # Log the event echo "$(date +"%Y-%m-%d %H:%M:%S") - start new application." >> $AUTO_DEPLOY_LOG else - # If there are no new changes in the remote dev branch + # If there are no new changes in the remote branch # Log the event echo "$(date +"%Y-%m-%d %H:%M:%S") - no change detected." >> $AUTO_DEPLOY_LOG From 0a14c39cbcab10ca09fbf1b1715b608651558044 Mon Sep 17 00:00:00 2001 From: Pil0tXia Date: Mon, 8 Apr 2024 19:56:47 +0800 Subject: [PATCH 2/3] README EngVer --- README.md | 63 ++++++++++++++++++++++++++++++++++++++++++------------- 1 file changed, 48 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index bf6fbb59..43c7db09 100644 --- a/README.md +++ b/README.md @@ -1,29 +1,60 @@ # EventMesh Dashboard -## 介绍 +[🌐 简体中文](README.zh-CN.md) -## 业务架构 +## Introduction -## 技术架构 +The EventMesh Dashboard is under development and will support functionalities such as Connection management, cluster health checks, etc. Feel free to reach out to the [EventMesh Assistant](https://github.com/apache/eventmesh?tab=readme-ov-file#community) to contribute. -### 环境 +The Dashboard for EventMesh, maintained during v1.8.0 ~ v1.10.0, is a pure frontend project located at the [Next.js Dashboard branch](https://github.com/apache/eventmesh-dashboard/tree/nextjs-dashboard). + +Weekly development meeting documents for EventMesh Dashboard: https://docs.qq.com/doc/DQmhVbklUdGNNWGZi + +## Technical Architecture + +### Environment - JDK 8/11 - Maven 3.8.1 - Spring Boot 2.7.x -### 模块依赖图 +### Module Introduction + +1. eventmesh-dashboard-console: Code for business modules, invoking service interfaces. +2. eventmesh-dashboard-observe: Code for monitoring modules. +3. eventmesh-dashboard-core: Code for EventMesh Runtime, Meta, and related components, providing service implementations. +4. eventmesh-dashboard-service: Common API interfaces, abstracting core functionalities. +5. eventmesh-dashboard-common: Code for common modules. +6. eventmesh-dashboard-view: Frontend code. + +## Auto Deploy EventMesh Dashboard + +When the repository code is updated, the script will build and run the EventMesh Dashboard based on the latest version of the code. + +### Usage + +``` +cd ~/service +git clone https://github.com/apache/eventmesh-dashboard.git +cd eventmesh-dashboard/deployment/ +``` + +Edit credentials: -### 模块介绍 +``` +cp .env.example .env +vim .env +``` -1. eventmesh-dashboard-console 业务模块的代码,调用service接口 -2. eventmesh-dashboard-observe 监控模块的代码 -3. eventmesh-dashboard-core 对EventMesh Runtime, Meta以及相关组件的代码,提供service实现 -4. eventmesh-dashboard-service 公用API接口,对core的抽象 -5. eventmesh-dashboard-common 公共模块的代码 -6. eventmesh-dashboard-view 前端代码 +Add task to crontab: + +``` +crontab -e +``` -### eventmesh-dashboard-core 介绍 +``` +0 * * * * bash ~/service/eventmesh-dashboard/deployment/auto-deploy-eventmesh-dashboard.sh +``` ## Build @@ -31,15 +62,17 @@ ``` cd eventmesh-dashboard -./gradlew clean bootJar +mvn clean package ``` ``` -java -jar build/libs/eventmesh-dashboard-0.0.1-SNAPSHOT.jar +java -DDB_ADDRESS=$DB_ADDRESS -DDB_USERNAME=$DB_USERNAME -DDB_PASSWORD=$DB_PASSWORD -jar eventmesh-dashboard-console/target/eventmesh-dashboard-console-0.0.1-SNAPSHOT.jar ``` ### Build and Run with Docker +>To be updated + ``` cd eventmesh-dashboard ./gradlew clean bootJar From 1fafd22780fab41407a2f29ddc4726ca1dcbbf5d Mon Sep 17 00:00:00 2001 From: Pil0tXia Date: Mon, 8 Apr 2024 20:00:06 +0800 Subject: [PATCH 3/3] README zh-CN ver --- README.zh-CN.md | 84 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 README.zh-CN.md diff --git a/README.zh-CN.md b/README.zh-CN.md new file mode 100644 index 00000000..5e45581f --- /dev/null +++ b/README.zh-CN.md @@ -0,0 +1,84 @@ +# EventMesh Dashboard + +[🌐 English Version](README.md) + +## 介绍 + +EventMesh Dashboard 处于开发中,将支持 Connection 管理、集群健康检查等功能。欢迎联系 [EventMesh 小助手](https://github.com/apache/eventmesh?tab=readme-ov-file#community)参与贡献。 + +EventMesh 于 v1.8.0 ~ v1.10.0 期间维护的 Dashboard 纯前端项目位于 [Next.js Dashboard 分支](https://github.com/apache/eventmesh-dashboard/tree/nextjs-dashboard)。 + +EventMesh Dashboard 每周开发例会文档:https://docs.qq.com/doc/DQmhVbklUdGNNWGZi + +## 技术架构 + +### 环境 + +- JDK 8/11 +- Maven 3.8.1 +- Spring Boot 2.7.x + +### 模块介绍 + +1. eventmesh-dashboard-console 业务模块的代码,调用service接口 +2. eventmesh-dashboard-observe 监控模块的代码 +3. eventmesh-dashboard-core 对EventMesh Runtime, Meta以及相关组件的代码,提供service实现 +4. eventmesh-dashboard-service 公用API接口,对core的抽象 +5. eventmesh-dashboard-common 公共模块的代码 +6. eventmesh-dashboard-view 前端代码 + +## 自动部署最新版 EventMesh Dashboard + +当仓库代码更新后,脚本将基于最新版本的代码构建并运行 EventMesh Dashboard。 + +### 快速开始 + +``` +cd ~/service +git clone https://github.com/apache/eventmesh-dashboard.git +cd eventmesh-dashboard/deployment/ +``` + +编辑凭据: + +``` +cp .env.example .env +vim .env +``` + +添加定时任务: + +``` +crontab -e +``` + +``` +0 * * * * bash ~/service/eventmesh-dashboard/deployment/auto-deploy-eventmesh-dashboard.sh +``` + +## 构建 + +### 使用源代码构建 + +``` +cd eventmesh-dashboard +mvn clean package +``` + +``` +java -DDB_ADDRESS=$DB_ADDRESS -DDB_USERNAME=$DB_USERNAME -DDB_PASSWORD=$DB_PASSWORD -jar eventmesh-dashboard-console/target/eventmesh-dashboard-console-0.0.1-SNAPSHOT.jar +``` + +### 构建并运行 Docker 镜像 + +>To be updated + +``` +cd eventmesh-dashboard +./gradlew clean bootJar +docker build -t yourname/eventmesh-dashboard -f docker/Dockerfile . +``` + +``` +docker run -d --name eventmesh-dashboard -p 8080:8080 yourname/eventmesh-dashboard +```