diff options
| author | shizhendong <[email protected]> | 2024-01-18 10:20:36 +0800 |
|---|---|---|
| committer | shizhendong <[email protected]> | 2024-01-18 10:20:36 +0800 |
| commit | 22a79e70cb43526b5b53d991598f98e7a08f4dff (patch) | |
| tree | b5f4a560614375b16cc97a4af0e4f897023bcb69 | |
| parent | 19f6b73d236ac2f96afd69251128915de05c0eb4 (diff) | |
build: rel-24.01.01rel-24.01.01
| -rw-r--r-- | .gitlab-ci.yml | 3 | ||||
| -rw-r--r-- | installtest/test.sh | 19 | ||||
| -rw-r--r-- | tools/nezha.properties | 6 | ||||
| -rw-r--r-- | tools/package.sh | 4 |
4 files changed, 7 insertions, 25 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 87fbcce..85bfda6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,12 +12,9 @@ variables: # mariadb 密码配置(必须),注意变量名是 MYSQL_ROOT_PASSWORD MYSQL_ROOT_PASSWORD: '111111' MYSQL_PORT: 3306 - # redis 端口定义 (必须) - REDIS_PORT: 6379 # 定义全局依赖的docker服务,即 这条流水线 pipeline 中的任务都用这里的服务 services: - mariadb:10.2.14 - - redis:6.2.5 # 开始执行脚本前所需执行脚本 before_script: - echo "begin ci" diff --git a/installtest/test.sh b/installtest/test.sh index 6a137f9..40339c0 100644 --- a/installtest/test.sh +++ b/installtest/test.sh @@ -4,7 +4,6 @@ CUR_PWD=`pwd` MYSQL_HOSTNAME="mariadb" MYSQL_ROOTUSERNAME="root" -REDIS_HOSTNAME="redis" RPM_PACKAGE_NAME="nz" RPM_INSTALL_PATH="/opt/nezha/nz-web" @@ -77,7 +76,7 @@ else fi # check_db -REQUEST_BODY="{\"database\":{\"host\":\"$MYSQL_HOSTNAME\",\"port\":$MYSQL_PORT,\"name\":\"$MYSQL_DATABASE\",\"username\":\"$MYSQL_ROOTUSERNAME\",\"pin\":\"$MYSQL_ROOT_PASSWORD\"},\"code\":\"$VALIDATE_CODE\"}" +REQUEST_BODY="{\"database\":{\"url\":[\"$MYSQL_HOSTNAME:$MYSQL_PORT\"],\"name\":\"$MYSQL_DATABASE\",\"username\":\"$MYSQL_ROOTUSERNAME\",\"pin\":\"$MYSQL_ROOT_PASSWORD\"},\"code\":\"$VALIDATE_CODE\"}" CHECKDB=`curl -k -m 10 -o /dev/null -s -w %{http_code} -X POST -H 'Content-Type:application/json;charset=UTF-8' -d "${REQUEST_BODY}" 'http://localhost/setup/checkDb'` if [ $CHECKDB -eq 200 ];then echo "db is connected" @@ -86,20 +85,10 @@ else exit 1 fi -# check_redis -REQUEST_BODY="{\"redis\":{\"host\":\"$REDIS_HOSTNAME\",\"port\":$REDIS_PORT,\"pin\":\"\"},\"code\":\"$VALIDATE_CODE\"}" -CHECKREDIS=`curl -k -m 10 -o /dev/null -s -w %{http_code} -X POST -H 'Content-Type:application/json;charset=UTF-8' -d "${REQUEST_BODY}" 'http://localhost/setup/checkRedis'` -if [ $CHECKREDIS -eq 200 ];then - echo "redis is connected" -else - echo "redis connection exception" - exit 1 -fi - # config -REQUEST_BODY="{\"database\":{\"host\":\"$MYSQL_HOSTNAME\",\"port\":$MYSQL_PORT,\"name\":\"$MYSQL_DATABASE\",\"username\":\"$MYSQL_ROOTUSERNAME\",\"pin\":\"$MYSQL_ROOT_PASSWORD\"},\ - \"redis\":{\"host\":\"$REDIS_HOSTNAME\",\"port\":$REDIS_PORT,\"pin\":\"\"},\ - \"system\":{\"username\":\"admin\",\"pin\":\"admin\",\"alertPrefix\":\"\",\"haMode\":1,\"haVip\":\"\",\"federationEnabled\":1},\ +REQUEST_BODY="{\"database\":{\"url\":[\"$MYSQL_HOSTNAME:$MYSQL_PORT\"],\"name\":\"$MYSQL_DATABASE\",\"username\":\"$MYSQL_ROOTUSERNAME\",\"pin\":\"$MYSQL_ROOT_PASSWORD\"},\ + \"adminUser\":{\"username\":\"admin\",\"pin\":\"admin\"},\ + \"system\":{\"timezone\":\"Asia/Shanghai\",\"language\":\"en\",\"federationEnabled\":\"1\",\"asset_ping_from\":\"1\",\"asset_ping_interval\":\"300\",\"default_scrape_interval\":\"30\",\"default_scrape_timeout\":\"30\",\"snmp_trap_listen_port\":\"162\"},\ \"code\":\"${VALIDATE_CODE}\"}" CONFIG_RESULT=`curl -k -m 10 -o /dev/null -s -w %{http_code} -X POST -H 'Content-Type:application/json;charset=UTF-8' -d "${REQUEST_BODY}" 'http://localhost/setup/config'` if [ $CONFIG_RESULT -eq 200 ];then diff --git a/tools/nezha.properties b/tools/nezha.properties index d73db8a..83225e6 100644 --- a/tools/nezha.properties +++ b/tools/nezha.properties @@ -1,10 +1,6 @@ server.port=80 nezha.inited=0 +database.url= database.name= -database.host= -database.port= database.user= database.pin= -redis.host= -redis.port= -redis.pin=
\ No newline at end of file diff --git a/tools/package.sh b/tools/package.sh index d872f15..6d9ef2a 100644 --- a/tools/package.sh +++ b/tools/package.sh @@ -16,9 +16,9 @@ RPM_FULL_NAME=${PACKAGE_NAME}-${PACKAGE_VERSION}-${ITERATION}.x86_64.rpm mc alias set nz $MINIO_HOST $MINIO_USER $MINIO_PWD #各个依赖包版本 -NZ_WEB_PKG="release/nz-web/nz-web-rel-23.10.09-5a48955e.tar.gz" +NZ_WEB_PKG="release/nz-web/nz-web-rel-24.01.01-5134f0d5.tar.gz" NZ_AGENT_PKG="release/nz-agent/nz-agent-23.10.02.c491be76-Release.x86_64.rpm" -NZ_GUI_PKG="release/nz-gui/nz-gui-7caa90d6.zip" +NZ_GUI_PKG="release/nz-gui/nz-gui-4bb6d027.zip" NZ_TALON_PKG="release/nz-talon/nz-talon-23.10.02.4bd4109f-Release.x86_64.rpm" # 依赖jdk 文件名 |
