Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
68c36479
T
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1184
Star
22015
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
68c36479
编写于
8月 29, 2022
作者:
H
Hui Li
提交者:
GitHub
8月 29, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #16483 from taosdata/test/chr/TD-14699
test: add checkpackages scritps
上级
c809633a
8a59420c
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
80 addition
and
21 deletion
+80
-21
packaging/MPtestJenkinsfile
packaging/MPtestJenkinsfile
+23
-15
packaging/checkPackageRuning.py
packaging/checkPackageRuning.py
+3
-1
packaging/testpackage.sh
packaging/testpackage.sh
+54
-5
未找到文件。
packaging/MPtestJenkinsfile
浏览文件 @
68c36479
def sync_source(branch_name) {
sh '''
hostname
IP
env
echo ''' + branch_name + '''
'''
...
...
@@ -15,6 +16,7 @@ def sync_source(branch_name) {
cd ${TDENGINE_ROOT_DIR}
git reset --hard
git fetch || git fetch
rm -rf examples/rust/
git checkout ''' + branch_name + ''' -f
git branch
git pull || git pull
...
...
@@ -53,6 +55,16 @@ pipeline {
defaultValue:'3.0.0.1',
description: 'This number of baseVerison is generally not modified.Now it is 3.0.0.1'
)
string (
name:'toolsVersion',
defaultValue:'2.1.2',
description: 'This number of baseVerison is generally not modified.Now it is 3.0.0.1'
)
string (
name:'toolsBaseVersion',
defaultValue:'2.1.2',
description: 'This number of baseVerison is generally not modified.Now it is 3.0.0.1'
)
}
environment{
WORK_DIR = '/var/lib/jenkins/workspace'
...
...
@@ -86,26 +98,18 @@ pipeline {
TD_CLIENT_EXE = "TDengine-client-${version}-Windows-x64.exe"
TD_TOOLS_TAR = "taosTools-${toolsVersion}-Linux-x64.tar.gz"
}
stages {
stage ('RUN') {
stage('get check package scritps'){
agent{label 'ubuntu18'}
steps {
catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
script{
sync_source("${BRANCH_NAME}")
}
}
}
}
parallel {
stage('ubuntu16') {
agent{label " ubuntu16 "}
steps {
timeout(time: 3, unit: 'MINUTES'){
timeout(time: 10, unit: 'MINUTES'){
sync_source("${BRANCH_NAME}")
sh '''
cd ${TDENGINE_ROOT_DIR}/packaging
bash testpackage.sh ${TD_SERVER_TAR} ${version} ${BASE_TD_SERVER_TAR} ${baseVersion} server
...
...
@@ -128,7 +132,8 @@ pipeline {
stage('ubuntu18') {
agent{label " ubuntu18 "}
steps {
timeout(time: 3, unit: 'MINUTES'){
timeout(time: 10, unit: 'MINUTES'){
sync_source("${BRANCH_NAME}")
sh '''
cd ${TDENGINE_ROOT_DIR}/packaging
bash testpackage.sh ${TD_SERVER_TAR} ${version} ${BASE_TD_SERVER_TAR} ${baseVersion} server
...
...
@@ -151,7 +156,8 @@ pipeline {
stage('centos7') {
agent{label " centos7_9 "}
steps {
timeout(time: 240, unit: 'MINUTES'){
timeout(time: 10, unit: 'MINUTES'){
sync_source("${BRANCH_NAME}")
sh '''
cd ${TDENGINE_ROOT_DIR}/packaging
bash testpackage.sh ${TD_SERVER_TAR} ${version} ${BASE_TD_SERVER_TAR} ${baseVersion} server
...
...
@@ -161,6 +167,7 @@ pipeline {
sh '''
cd ${TDENGINE_ROOT_DIR}/packaging
bash testpackage.sh ${TD_SERVER_LITE_TAR} ${version} ${BASE_TD_SERVER_LITE_TAR} ${baseVersion} server
bash testpackage.sh ${TD_SERVER_LITE_TAR} ${version} ${BASE_TD_SERVER_LITE_TAR} ${baseVersion} server
python3 checkPackageRuning.py
'''
sh '''
...
...
@@ -174,7 +181,8 @@ pipeline {
stage('centos8') {
agent{label " centos8_3 "}
steps {
timeout(time: 240, unit: 'MINUTES'){
timeout(time: 10, unit: 'MINUTES'){
sync_source("${BRANCH_NAME}")
sh '''
cd ${TDENGINE_ROOT_DIR}/packaging
bash testpackage.sh ${TD_SERVER_TAR} ${version} ${BASE_TD_SERVER_TAR} ${baseVersion} server
...
...
packaging/checkPackageRuning.py
浏览文件 @
68c36479
...
...
@@ -22,10 +22,12 @@ import time
# install taospy
out
=
subprocess
.
getoutput
(
"pip3 show taospy|grep Version| awk -F ':' '{print $2}' "
)
print
(
out
)
print
(
"taospy version %s "
%
out
)
if
(
out
==
""
):
os
.
system
(
"pip install git+https://github.com/taosdata/taos-connector-python.git"
)
print
(
"install taos python connector"
)
else
:
os
.
system
(
"pip3 install --upgrade taospy "
)
...
...
packaging/testpackage.sh
浏览文件 @
68c36479
#!/bin/sh
# function installPkgAndCheckFile{
echo
"Download package"
# # ============================= get input parameters =================================================
# # install.sh -v [server | client] -e [yes | no] -i [systemd | service | ...]
# # set parameters by default value
# interactiveFqdn=yes # [yes | no]
# verType=server # [server | client]
# initType=systemd # [systemd | service | ...]
# while getopts "hv:d:" arg
# do
# case $arg in
# d)
# #echo "interactiveFqdn=$OPTARG"
# script_dir=$( echo $OPTARG )
# ;;
# h)
# echo "Usage: `basename $0` -d scripy_path"
# exit 0
# ;;
# ?) #unknow option
# echo "unkonw argument"
# exit 1
# ;;
# esac
# done
# echo "Download package"
packgeName
=
$1
version
=
$2
...
...
@@ -25,22 +49,42 @@ elif [ ${testFile} = "tools" ];then
installCmd
=
"install-taostools.sh"
fi
function
cmdInstall
{
comd
=
$1
if
command
-v
${
comd
}
;
then
echo
"
${
comd
}
is already installed"
else
if
command
-v
apt
;
then
apt-get
install
${
comd
}
elif
command
-v
yum
;
then
yum
install
${
comd
}
else
echo
"you should install
${
comd
}
manually"
fi
fi
}
echo
"Uninstall all components of TDeingne"
if
command
-v
rmtaos
;
then
echo
"uninstall all components of TDeingne:rmtaos"
echo
" "
rmtaos
else
echo
"os doesn't include TDengine "
fi
if
command
-v
rmtaostools
;
then
echo
"uninstall all components of TDeingne:rmtaostools"
echo
" "
rmtaostools
else
echo
"os doesn't include rmtaostools "
fi
cmdInstall tree
cmdInstall wget
echo
"new workroom path"
installPath
=
"/usr/local/src/packageTest"
oriInstallPath
=
"/usr/local/src/packageTest/3.1"
...
...
@@ -104,6 +148,11 @@ elif [[ ${packgeName} =~ "tar" ]];then
else
bash
${
installCmd
}
fi
if
[[
${
packgeName
}
=
~
"Lite"
]]
;
then
cd
${
installPath
}
wget https://www.taosdata.com/assets-download/3.0/taosTools-2.1.2-Linux-x64.tar.gz
tar
xvf taosTools-2.1.2-Linux-x64.tar.gz
cd
taosTools-2.1.2
&&
bash install-taostools.sh
fi
# }
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录