Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Chu Peng 楚鹏
minikube
提交
2936722d
M
minikube
项目概览
Chu Peng 楚鹏
/
minikube
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
minikube
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
2936722d
编写于
4月 18, 2020
作者:
M
Medya Gh
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add master workflow
上级
8c6fda6b
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
459 addition
and
2 deletion
+459
-2
.github/workflows/master.yml
.github/workflows/master.yml
+456
-0
.github/workflows/pr.yml
.github/workflows/pr.yml
+3
-2
未找到文件。
.github/workflows/master.yml
0 → 100644
浏览文件 @
2936722d
name
:
master
on
:
push
:
path
:
-
'
**.go'
branches
:
-
master
# Push events on master branch paths:
env
:
GOPROXY
:
https://proxy.golang.org
jobs
:
# Runs before all other jobs
# builds the minikube binaries
build_minikube
:
runs-on
:
ubuntu-18.04
steps
:
-
uses
:
actions/checkout@v2
-
name
:
Download Dependencies
run
:
go mod download
-
name
:
Build Binaries
run
:
|
make minikube-linux-amd64
make e2e-linux-amd64
cp -r test/integration/testdata ./out
whoami
echo github ref $GITHUB_REF
echo workflow $GITHUB_WORKFLOW
echo home $HOME
echo event name $GITHUB_EVENT_NAME
echo workspace $GITHUB_WORKSPACE
echo "end of debug stuff"
echo $(which jq)
-
uses
:
actions/upload-artifact@v1
with
:
name
:
minikube_binaries
path
:
out
lint
:
runs-on
:
ubuntu-18.04
steps
:
-
uses
:
actions/checkout@v2
-
name
:
Install libvirt
run
:
|
sudo apt-get update
sudo apt-get install -y libvirt-dev
-
name
:
Download Dependencies
run
:
go mod download
-
name
:
Lint
env
:
TESTSUITE
:
lintall
run
:
make test
continue-on-error
:
false
unit_test
:
runs-on
:
ubuntu-18.04
steps
:
-
uses
:
actions/checkout@v2
-
name
:
Install libvirt
run
:
|
sudo apt-get update
sudo apt-get install -y libvirt-dev
-
name
:
Download Dependencies
run
:
go mod download
-
name
:
Unit Test
env
:
TESTSUITE
:
unittest
run
:
make test
continue-on-error
:
false
# Run the following integration tests after the build_minikube
# They will run in parallel and use the binaries in previous step
functional_test_docker_ubuntu
:
needs
:
[
build_minikube
]
env
:
TIME_ELAPSED
:
time
JOB_NAME
:
"
functional_test_docker_ubuntu"
GOPOGH_RESULT
:
"
"
SHELL
:
"
/bin/bash"
# To prevent https://github.com/kubernetes/minikube/issues/6643
runs-on
:
ubuntu-18.04
steps
:
-
name
:
Install kubectl
shell
:
bash
run
:
|
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.18.0/bin/linux/amd64/kubectl
sudo install kubectl /usr/local/bin/kubectl
kubectl version --client=true
-
name
:
Docker Info
shell
:
bash
run
:
|
echo "--------------------------"
docker version || true
echo "--------------------------"
docker info || true
echo "--------------------------"
docker system df || true
echo "--------------------------"
docker system info || true
echo "--------------------------"
docker ps || true
echo "--------------------------"
-
name
:
Install lz4
shell
:
bash
run
:
|
sudo apt-get update -qq
sudo apt-get -qq -y install liblz4-tool
-
name
:
Install gopogh
shell
:
bash
run
:
|
curl -LO https://github.com/medyagh/gopogh/releases/download/v0.1.19/gopogh-linux-amd64
sudo install gopogh-linux-amd64 /usr/local/bin/gopogh
-
name
:
Download Binaries
uses
:
actions/download-artifact@v1
with
:
name
:
minikube_binaries
-
name
:
Run Integration Test
continue-on-error
:
false
# bash {0} to allow test to continue to next step. in case of
shell
:
bash {0}
run
:
|
cd minikube_binaries
mkdir -p report
mkdir -p testhome
chmod a+x e2e-*
chmod a+x minikube-*
sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
START_TIME=$(date -u +%s)
KUBECONFIG=$(pwd)/testhome/kubeconfig MINIKUBE_HOME=$(pwd)/testhome ./e2e-linux-amd64 -minikube-start-args=--vm-driver=docker -test.run TestFunctional -test.timeout=30m -test.v -timeout-multiplier=1.5 -binary=./minikube-linux-amd64 2>&1 | tee ./report/testout.txt
END_TIME=$(date -u +%s)
TIME_ELAPSED=$(($END_TIME-$START_TIME))
min=$((${TIME_ELAPSED}/60))
sec=$((${TIME_ELAPSED}%60))
TIME_ELAPSED="${min} min $sec seconds "
echo ::set-env name=TIME_ELAPSED::${TIME_ELAPSED}
-
name
:
Generate HTML Report
shell
:
bash
run
:
|
cd minikube_binaries
export PATH=${PATH}:`go env GOPATH`/bin
go tool test2json -t < ./report/testout.txt > ./report/testout.json || true
STAT=$(gopogh -in ./report/testout.json -out ./report/testout.html -name "${JOB_NAME} ${GITHUB_REF}" -repo "${GITHUB_REPOSITORY}" -details "${GITHUB_SHA}") || true
echo status: ${STAT}
FailNum=$(echo $STAT | jq '.NumberOfFail')
TestsNum=$(echo $STAT | jq '.NumberOfTests')
GOPOGH_RESULT="${JOB_NAME} : completed with ${FailNum} / ${TestsNum} failures in ${TIME_ELAPSED}"
echo ::set-env name=GOPOGH_RESULT::${GOPOGH_RESULT}
echo ::set-env name=STAT::${STAT}
-
uses
:
actions/upload-artifact@v1
with
:
name
:
functional_test_docker_ubuntu
path
:
minikube_binaries/report
-
name
:
The End Result functional_test_docker_ubuntu
shell
:
bash
run
:
|
echo ${GOPOGH_RESULT}
numFail=$(echo $STAT | jq '.NumberOfFail')
echo "----------------${numFail} Failures----------------------------"
echo $STAT | jq '.FailedTests' || true
echo "-------------------------------------------------------"
numPass=$(echo $STAT | jq '.NumberOfPass')
echo "*** $numPass Passed ***"
if [ "$numFail" -gt 0 ];then echo "*** $numFail Failed ***";exit 2;fi
addons_certs_tests_docker_ubuntu
:
runs-on
:
ubuntu-18.04
env
:
TIME_ELAPSED
:
time
JOB_NAME
:
"
addons_certs_tests_docker_ubuntu"
GOPOGH_RESULT
:
"
"
SHELL
:
"
/bin/bash"
# To prevent https://github.com/kubernetes/minikube/issues/6643
needs
:
[
build_minikube
]
steps
:
-
name
:
Install kubectl
shell
:
bash
run
:
|
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.18.0/bin/linux/amd64/kubectl
sudo install kubectl /usr/local/bin/kubectl
kubectl version --client=true
-
name
:
Install lz4
shell
:
bash
run
:
|
sudo apt-get update -qq
sudo apt-get -qq -y install liblz4-tool
-
name
:
Docker Info
shell
:
bash
run
:
|
echo "--------------------------"
docker version || true
echo "--------------------------"
docker info || true
echo "--------------------------"
docker system df || true
echo "--------------------------"
docker system info || true
echo "--------------------------"
docker ps || true
echo "--------------------------"
-
name
:
Install gopogh
shell
:
bash
run
:
|
curl -LO https://github.com/medyagh/gopogh/releases/download/v0.1.19/gopogh-linux-amd64
sudo install gopogh-linux-amd64 /usr/local/bin/gopogh
-
name
:
Download Binaries
uses
:
actions/download-artifact@v1
with
:
name
:
minikube_binaries
-
name
:
Run Integration Test
continue-on-error
:
true
# bash {0} to allow test to continue to next step. in case of
shell
:
bash {0}
run
:
|
cd minikube_binaries
mkdir -p report
mkdir -p testhome
chmod a+x e2e-*
chmod a+x minikube-*
sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
START_TIME=$(date -u +%s)
KUBECONFIG=$(pwd)/testhome/kubeconfig MINIKUBE_HOME=$(pwd)/testhome ./e2e-linux-amd64 -minikube-start-args=--driver=docker -test.run "(TestAddons|TestCertOptions)" -test.timeout=30m -test.v -timeout-multiplier=1.5 -binary=./minikube-linux-amd64 2>&1 | tee ./report/testout.txt
END_TIME=$(date -u +%s)
TIME_ELAPSED=$(($END_TIME-$START_TIME))
min=$((${TIME_ELAPSED}/60))
sec=$((${TIME_ELAPSED}%60))
TIME_ELAPSED="${min} min $sec seconds "
echo ::set-env name=TIME_ELAPSED::${TIME_ELAPSED}
-
name
:
Generate HTML Report
shell
:
bash
run
:
|
cd minikube_binaries
export PATH=${PATH}:`go env GOPATH`/bin
go tool test2json -t < ./report/testout.txt > ./report/testout.json || true
STAT=$(gopogh -in ./report/testout.json -out ./report/testout.html -name "${JOB_NAME} ${GITHUB_REF}" -repo "${GITHUB_REPOSITORY}" -details "${GITHUB_SHA}") || true
echo status: ${STAT}
FailNum=$(echo $STAT | jq '.NumberOfFail')
TestsNum=$(echo $STAT | jq '.NumberOfTests')
GOPOGH_RESULT="${JOB_NAME} : completed with ${FailNum} / ${TestsNum} failures in ${TIME_ELAPSED}"
echo ::set-env name=GOPOGH_RESULT::${GOPOGH_RESULT}
echo ::set-env name=STAT::${STAT}
-
uses
:
actions/upload-artifact@v1
with
:
name
:
addons_certs_tests_docker_ubuntu
path
:
minikube_binaries/report
-
name
:
The End Result - addons_certs_tests_docker_ubuntu
shell
:
bash
run
:
|
echo ${GOPOGH_RESULT}
numFail=$(echo $STAT | jq '.NumberOfFail')
echo "----------------${numFail} Failures----------------------------"
echo $STAT | jq '.FailedTests' || true
echo "-------------------------------------------------------"
numPass=$(echo $STAT | jq '.NumberOfPass')
echo "*** $numPass Passed ***"
if [ "$numFail" -gt 0 ];then echo "*** $numFail Failed ***";exit 2;fi
multinode_pause_tests_docker_ubuntu
:
runs-on
:
ubuntu-18.04
env
:
TIME_ELAPSED
:
time
JOB_NAME
:
"
multinode_pause_tests_docker_ubuntu"
GOPOGH_RESULT
:
"
"
SHELL
:
"
/bin/bash"
# To prevent https://github.com/kubernetes/minikube/issues/6643
needs
:
[
build_minikube
]
steps
:
-
name
:
Install kubectl
shell
:
bash
run
:
|
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.18.0/bin/linux/amd64/kubectl
sudo install kubectl /usr/local/bin/kubectl
kubectl version --client=true
-
name
:
Install lz4
shell
:
bash
run
:
|
sudo apt-get update -qq
sudo apt-get -qq -y install liblz4-tool
-
name
:
Docker Info
shell
:
bash
run
:
|
echo "--------------------------"
docker version || true
echo "--------------------------"
docker info || true
echo "--------------------------"
docker system df || true
echo "--------------------------"
docker system info || true
echo "--------------------------"
docker ps || true
echo "--------------------------"
-
name
:
Install gopogh
shell
:
bash
run
:
|
curl -LO https://github.com/medyagh/gopogh/releases/download/v0.1.19/gopogh-linux-amd64
sudo install gopogh-linux-amd64 /usr/local/bin/gopogh
-
name
:
Download Binaries
uses
:
actions/download-artifact@v1
with
:
name
:
minikube_binaries
-
name
:
Run Integration Test
continue-on-error
:
true
# bash {0} to allow test to continue to next step. in case of
shell
:
bash {0}
run
:
|
cd minikube_binaries
mkdir -p report
mkdir -p testhome
chmod a+x e2e-*
chmod a+x minikube-*
sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
START_TIME=$(date -u +%s)
KUBECONFIG=$(pwd)/testhome/kubeconfig MINIKUBE_HOME=$(pwd)/testhome ./e2e-linux-amd64 -minikube-start-args=--driver=docker -test.run "(TestPause|TestMultiNode)" -test.timeout=30m -test.v -timeout-multiplier=1.5 -binary=./minikube-linux-amd64 2>&1 | tee ./report/testout.txt
END_TIME=$(date -u +%s)
TIME_ELAPSED=$(($END_TIME-$START_TIME))
min=$((${TIME_ELAPSED}/60))
sec=$((${TIME_ELAPSED}%60))
TIME_ELAPSED="${min} min $sec seconds "
echo ::set-env name=TIME_ELAPSED::${TIME_ELAPSED}
-
name
:
Generate HTML Report
shell
:
bash
run
:
|
cd minikube_binaries
export PATH=${PATH}:`go env GOPATH`/bin
go tool test2json -t < ./report/testout.txt > ./report/testout.json || true
STAT=$(gopogh -in ./report/testout.json -out ./report/testout.html -name "${JOB_NAME} ${GITHUB_REF}" -repo "${GITHUB_REPOSITORY}" -details "${GITHUB_SHA}") || true
echo status: ${STAT}
FailNum=$(echo $STAT | jq '.NumberOfFail')
TestsNum=$(echo $STAT | jq '.NumberOfTests')
GOPOGH_RESULT="${JOB_NAME} : completed with ${FailNum} / ${TestsNum} failures in ${TIME_ELAPSED}"
echo ::set-env name=GOPOGH_RESULT::${GOPOGH_RESULT}
echo ::set-env name=STAT::${STAT}
-
uses
:
actions/upload-artifact@v1
with
:
name
:
multinode_pause_tests_docker_ubuntu
path
:
minikube_binaries/report
-
name
:
The End Result - multinode_pause_tests_docker_ubuntu
shell
:
bash
run
:
|
echo ${GOPOGH_RESULT}
numFail=$(echo $STAT | jq '.NumberOfFail')
echo "----------------${numFail} Failures----------------------------"
echo $STAT | jq '.FailedTests' || true
echo "-------------------------------------------------------"
numPass=$(echo $STAT | jq '.NumberOfPass')
echo "*** $numPass Passed ***"
if [ "$numFail" -gt 0 ];then echo "*** $numFail Failed ***";exit 2;fi
preload_docker_flags_tests_docker_ubuntu
:
runs-on
:
ubuntu-18.04
env
:
TIME_ELAPSED
:
time
JOB_NAME
:
"
preload_docker_flags_tests_docker_ubuntu"
GOPOGH_RESULT
:
"
"
SHELL
:
"
/bin/bash"
# To prevent https://github.com/kubernetes/minikube/issues/6643
needs
:
[
build_minikube
]
steps
:
-
name
:
Install kubectl
shell
:
bash
run
:
|
curl -LO https://storage.googleapis.com/kubernetes-release/release/v1.18.0/bin/linux/amd64/kubectl
sudo install kubectl /usr/local/bin/kubectl
kubectl version --client=true
-
name
:
Install lz4
shell
:
bash
run
:
|
sudo apt-get update -qq
sudo apt-get -qq -y install liblz4-tool
-
name
:
Docker Info
shell
:
bash
run
:
|
echo "--------------------------"
docker version || true
echo "--------------------------"
docker info || true
echo "--------------------------"
docker system df || true
echo "--------------------------"
docker system info || true
echo "--------------------------"
docker ps || true
echo "--------------------------"
-
name
:
Install gopogh
shell
:
bash
run
:
|
curl -LO https://github.com/medyagh/gopogh/releases/download/v0.1.19/gopogh-linux-amd64
sudo install gopogh-linux-amd64 /usr/local/bin/gopogh
-
name
:
Download Binaries
uses
:
actions/download-artifact@v1
with
:
name
:
minikube_binaries
-
name
:
Run Integration Test
continue-on-error
:
true
# bash {0} to allow test to continue to next step. in case of
shell
:
bash {0}
run
:
|
cd minikube_binaries
mkdir -p report
mkdir -p testhome
chmod a+x e2e-*
chmod a+x minikube-*
sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
START_TIME=$(date -u +%s)
KUBECONFIG=$(pwd)/testhome/kubeconfig MINIKUBE_HOME=$(pwd)/testhome ./e2e-linux-amd64 -minikube-start-args=--driver=docker -test.run "(TestPreload|TestDockerFlags)" -test.timeout=30m -test.v -timeout-multiplier=1.5 -binary=./minikube-linux-amd64 2>&1 | tee ./report/testout.txt
END_TIME=$(date -u +%s)
TIME_ELAPSED=$(($END_TIME-$START_TIME))
min=$((${TIME_ELAPSED}/60))
sec=$((${TIME_ELAPSED}%60))
TIME_ELAPSED="${min} min $sec seconds "
echo ::set-env name=TIME_ELAPSED::${TIME_ELAPSED}
-
name
:
Generate HTML Report
shell
:
bash
run
:
|
cd minikube_binaries
export PATH=${PATH}:`go env GOPATH`/bin
go tool test2json -t < ./report/testout.txt > ./report/testout.json || true
STAT=$(gopogh -in ./report/testout.json -out ./report/testout.html -name "${JOB_NAME} ${GITHUB_REF}" -repo "${GITHUB_REPOSITORY}" -details "${GITHUB_SHA}") || true
echo status: ${STAT}
FailNum=$(echo $STAT | jq '.NumberOfFail')
TestsNum=$(echo $STAT | jq '.NumberOfTests')
GOPOGH_RESULT="${JOB_NAME} : completed with ${FailNum} / ${TestsNum} failures in ${TIME_ELAPSED}"
echo ::set-env name=GOPOGH_RESULT::${GOPOGH_RESULT}
echo ::set-env name=STAT::${STAT}
-
uses
:
actions/upload-artifact@v1
with
:
name
:
preload_docker_flags_tests_docker_ubuntu
path
:
minikube_binaries/report
-
name
:
The End Result - preload_docker_flags_tests_docker_ubuntu
shell
:
bash
run
:
|
echo ${GOPOGH_RESULT}
numFail=$(echo $STAT | jq '.NumberOfFail')
echo "----------------${numFail} Failures----------------------------"
echo $STAT | jq '.FailedTests' || true
echo "-------------------------------------------------------"
numPass=$(echo $STAT | jq '.NumberOfPass')
echo "*** $numPass Passed ***"
if [ "$numFail" -gt 0 ];then echo "*** $numFail Failed ***";exit 2;fi
# collect all the reports and upload them
upload_all_reports
:
if
:
always()
needs
:
[
functional_test_docker_ubuntu
,
addons_certs_tests_docker_ubuntu
,
multinode_pause_tests_docker_ubuntu
,
preload_docker_flags_tests_docker_ubuntu
]
runs-on
:
ubuntu-18.04
steps
:
-
name
:
download all reports
uses
:
actions/download-artifact@v2-preview
-
name
:
upload all reports
shell
:
bash {0}
continue-on-error
:
true
run
:
|
mkdir -p all_reports
ls -lah
ls -lah minikube_binaries
ls -lah minikube_binaries/report
cp -r ./minikube_binaries/report/functional_test_docker_ubuntu ./all_reports/
cp -r ./minikube_binaries/report/addons_certs_tests_docker_ubuntu ./all_reports/
cp -r ./minikube_binaries/report/multinode_pause_tests_docker_ubuntu ./all_reports/
cp -r ./minikube_binaries/report/preload_docker_flags_tests_docker_ubuntu
-
uses
:
actions/upload-artifact@v1
with
:
name
:
all_reports
path
:
all_reports
.github/workflows/
main
.yml
→
.github/workflows/
pr
.yml
浏览文件 @
2936722d
name
:
CI
on
:
-
pull_request
-
push
paths
:
-
'
**.go'
env
:
GOPROXY
:
https://proxy.golang.org
jobs
:
...
...
@@ -512,7 +513,7 @@ jobs:
# collect all the reports and upload them
upload_all_reports
:
if
:
always()
needs
:
[
functional_test_docker_ubuntu
,
addons_certs_tests_docker_ubuntu
,
multinode_pause_tests_docker_ubuntu
,
preload_docker_flags_tests_docker_ubuntu
,
baremetal_ubuntu18_04
]
needs
:
[
functional_test_docker_ubuntu
,
addons_certs_tests_docker_ubuntu
,
multinode_pause_tests_docker_ubuntu
,
preload_docker_flags_tests_docker_ubuntu
]
runs-on
:
ubuntu-18.04
steps
:
-
name
:
download all reports
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录