Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
infrastructure
提交
4c5165bd
I
infrastructure
项目概览
openeuler
/
infrastructure
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
I
infrastructure
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
4c5165bd
编写于
11月 04, 2019
作者:
T
TommyLike
提交者:
Gitee
11月 04, 2019
浏览文件
操作
浏览文件
下载
差异文件
!20 update jenkins slave script
Merge pull request !20 from TommyLike/feature/last_jekins_test
上级
70bfcdff
edd49479
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
82 addition
and
9 deletion
+82
-9
ci/slave-scripts/centos.sh
ci/slave-scripts/centos.sh
+40
-3
ci/slave-scripts/opensuse.sh
ci/slave-scripts/opensuse.sh
+37
-3
ci/slave-scripts/setup.sh
ci/slave-scripts/setup.sh
+3
-1
obs/tf/startup/README.md
obs/tf/startup/README.md
+1
-1
obs/tf/startup/download_package_codes/projects_raw.xml
obs/tf/startup/download_package_codes/projects_raw.xml
+1
-1
未找到文件。
ci/slave-scripts/centos.sh
浏览文件 @
4c5165bd
#!/usr/bin/env bash
disk_name
=
$1
frontend_host
=
$2
backend_host
=
$3
if
[[
!
-e
${
disk_name
}
]]
;
then
echo
"disk
${
disk_name
}
not existed"
...
...
@@ -12,13 +14,48 @@ if [[ ! -e ~/.ssh/authorized_keys ]]; then
exit
1
fi
if
[[
!
-e
/etc/yum.repos.d/OSC.repo
]]
;
then
curl
-o
/etc/yum.repos.d/OSC.repo http://download.opensuse.org/repositories/openSUSE:/Tools/CentOS_7/openSUSE:Tools.repo
fi
# install required tools
sudo
yum
install
-y
java-1.8.0-openjdk
sudo
yum
install
-y
git
sudo
yum
install
-y
expect
sudo
yum
install
-y
osc
#update osc config file
if
[[
!
-d
/root/.config/osc
]]
;
then
mkdir
-p
/root/.config/osc
fi
if
[[
-e
/root/.config/osc/oscrc
]]
;
then
rm
/root/.config/osc/oscrc
fi
cd
/root/.config/osc
curl
-o
oscrc https://openeuler.obs.cn-south-1.myhuaweicloud.com:443/infrastructure/oscrc
sed
-i
"s/#no_verify = 1/no_verify = 1/g"
/root/.config/osc/oscrc
# update /etc/hosts
echo
"Updating the cluster hosts info"
# update hosts info:
# 1. <frontend_host> build.openeuler.org
if
!
grep
-q
"build.openeuler.org"
/etc/hosts
;
then
echo
"
${
frontend_host
}
build.openeuler.org"
>>
/etc/hosts
else
sed
-i
-e
"s/[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}
build.openeuler.org/
${
frontend_host
}
build.openeuler.org/g"
/etc/hosts
fi
if
!
grep
-q
"backend.openeuler.org"
/etc/hosts
;
then
echo
"
${
backend_host
}
backend.openeuler.org"
>>
/etc/hosts
else
sed
-i
-e
"s/[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}
backend.openeuler.org/
${
backend_host
}
backend.openeuler.org/g"
/etc/hosts
fi
# prepare disk
mkfs.ext4
${
disk_name
}
mkdir
/jenkins_home
mount
${
disk_name
}
/jenkins_home
if
[[
!
-d
/jenkins_home
]]
;
then
mkfs.ext4
${
disk_name
}
mkdir
/jenkins_home
mount
${
disk_name
}
/jenkins_home
fi
chmod
600 ~/.ssh/authorized_keys
ci/slave-scripts/opensuse.sh
浏览文件 @
4c5165bd
#!/usr/bin/env bash
disk_name
=
$1
frontend_host
=
$2
backend_host
=
$3
if
[[
!
-e
${
disk_name
}
]]
;
then
echo
"disk
${
disk_name
}
not existed"
...
...
@@ -15,10 +17,42 @@ fi
# install required tools
zypper
install
-y
java-1_8_0-openjdk
zypper
install
-y
git
zypper
install
-y
osc
zypper
install
-y
expect
#update osc config file
if
[[
!
-d
/root/.config/osc
]]
;
then
mkdir
-p
/root/.config/osc
fi
if
[[
-e
/root/.config/osc/oscrc
]]
;
then
rm
/root/.config/osc/oscrc
fi
cd
/root/.config/osc
curl
-o
oscrc https://openeuler.obs.cn-south-1.myhuaweicloud.com:443/infrastructure/oscrc
sed
-i
"s/#no_verify = 1/no_verify = 1/g"
/root/.config/osc/oscrc
# update /etc/hosts
echo
"Updating the cluster hosts info"
# update hosts info:
# 1. <frontend_host> build.openeuler.org
if
!
grep
-q
"build.openeuler.org"
/etc/hosts
;
then
echo
"
${
frontend_host
}
build.openeuler.org"
>>
/etc/hosts
else
sed
-i
-e
"s/[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}
build.openeuler.org/
${
frontend_host
}
build.openeuler.org/g"
/etc/hosts
fi
if
!
grep
-q
"backend.openeuler.org"
/etc/hosts
;
then
echo
"
${
backend_host
}
backend.openeuler.org"
>>
/etc/hosts
else
sed
-i
-e
"s/[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}\.
[0-9]
\{
1,3
\}
backend.openeuler.org/
${
backend_host
}
backend.openeuler.org/g"
/etc/hosts
fi
# prepare disk
mkfs.ext4
${
disk_name
}
mkdir
/jenkins_home
mount
${
disk_name
}
/jenkins_home
if
[[
!
-d
/jenkins_home
]]
;
then
mkfs.ext4
${
disk_name
}
mkdir
/jenkins_home
mount
${
disk_name
}
/jenkins_home
fi
chmod
600 ~/.ssh/authorized_keys
ci/slave-scripts/setup.sh
浏览文件 @
4c5165bd
...
...
@@ -4,6 +4,8 @@
script_name
=
$1
ip_address
=
$2
disk_name
=
$3
frontend_name
=
$4
backend_name
=
$5
scp ./authorized_keys root@
${
ip_address
}
:~/.ssh/
scp ./
${
script_name
}
root@
${
ip_address
}
:~/
ssh root@
${
ip_address
}
"chmod +x ~/
${
script_name
}
&& ~/
${
script_name
}
${
disk_name
}
"
\ No newline at end of file
ssh root@
${
ip_address
}
"chmod +x ~/
${
script_name
}
&& ~/
${
script_name
}
${
disk_name
}
${
frontend_name
}
${
backend_name
}
"
obs/tf/startup/README.md
浏览文件 @
4c5165bd
...
...
@@ -123,7 +123,7 @@ Worker6: 172.16.1.195
Worker7: 172.16.1.127
Worker8: 172.16.1.12
Worker9: 172.16.1.14
Worker10: 172.16.1.
1
57
Worker10: 172.16.1.57
```
## download full fedora packages
...
...
obs/tf/startup/download_package_codes/projects_raw.xml
浏览文件 @
4c5165bd
...
...
@@ -657,7 +657,7 @@
<project
path=
"openEuler/perl-Text-Balanced"
name=
"euleros/third_party/open_source/userspace/perl-Text-Balanced"
revision=
""
/>
<project
path=
"openEuler/perl-Text-Diff"
name=
"euleros/third_party/open_source/userspace/perl-Text-Diff"
revision=
""
/>
<project
path=
"openEuler/perl-Text-ParseWords"
name=
"euleros/third_party/open_source/userspace/perl-Text-ParseWords"
revision=
""
/>
<project
path=
"openEuler/perl-Text-Tabs
+
Wrap"
name=
"euleros/third_party/open_source/userspace/perl-Text-Tabs+Wrap"
revision=
""
/>
<project
path=
"openEuler/perl-Text-Tabs
-
Wrap"
name=
"euleros/third_party/open_source/userspace/perl-Text-Tabs+Wrap"
revision=
""
/>
<project
path=
"openEuler/perl-Thread-Queue"
name=
"euleros/third_party/open_source/userspace/perl-Thread-Queue"
revision=
""
/>
<project
path=
"openEuler/perl-threads"
name=
"euleros/third_party/open_source/userspace/perl-threads"
revision=
""
/>
<project
path=
"openEuler/perl-threads-shared"
name=
"euleros/third_party/open_source/userspace/perl-threads-shared"
revision=
""
/>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录