Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Chu Peng 楚鹏
minikube
提交
118e9cc0
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,发现更多精彩内容 >>
提交
118e9cc0
编写于
10月 19, 2018
作者:
T
Thomas Stromberg
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Apply go 1.11 formatting using `gofmt -s -l -w`
上级
88f2676b
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
28 addition
and
28 deletion
+28
-28
cmd/minikube/cmd/config/config_test.go
cmd/minikube/cmd/config/config_test.go
+4
-4
cmd/minikube/cmd/config/configure.go
cmd/minikube/cmd/config/configure.go
+7
-7
pkg/minikube/config/config_test.go
pkg/minikube/config/config_test.go
+4
-4
pkg/minikube/service/service_test.go
pkg/minikube/service/service_test.go
+12
-12
pkg/util/crypto.go
pkg/util/crypto.go
+1
-1
未找到文件。
cmd/minikube/cmd/config/config_test.go
浏览文件 @
118e9cc0
...
@@ -47,10 +47,10 @@ var configTestCases = []configTestCase{
...
@@ -47,10 +47,10 @@ var configTestCases = []configTestCase{
"vm-driver": "kvm"
"vm-driver": "kvm"
}`
,
}`
,
config
:
map
[
string
]
interface
{}{
config
:
map
[
string
]
interface
{}{
"vm-driver"
:
"kvm"
,
"vm-driver"
:
"kvm"
,
"cpus"
:
4
,
"cpus"
:
4
,
"disk-size"
:
"20g"
,
"disk-size"
:
"20g"
,
"v"
:
5
,
"v"
:
5
,
"show-libmachine-logs"
:
true
,
"show-libmachine-logs"
:
true
,
"log_dir"
:
"/etc/hosts"
,
"log_dir"
:
"/etc/hosts"
,
"ReminderWaitPeriodInHours"
:
99
,
"ReminderWaitPeriodInHours"
:
99
,
...
...
cmd/minikube/cmd/config/configure.go
浏览文件 @
118e9cc0
...
@@ -105,8 +105,8 @@ var addonsConfigureCmd = &cobra.Command{
...
@@ -105,8 +105,8 @@ var addonsConfigureCmd = &cobra.Command{
"aws-assume-role"
:
awsRole
,
"aws-assume-role"
:
awsRole
,
},
},
map
[
string
]
string
{
map
[
string
]
string
{
"app"
:
"registry-creds"
,
"app"
:
"registry-creds"
,
"cloud"
:
"ecr"
,
"cloud"
:
"ecr"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
})
})
...
@@ -120,11 +120,11 @@ var addonsConfigureCmd = &cobra.Command{
...
@@ -120,11 +120,11 @@ var addonsConfigureCmd = &cobra.Command{
"registry-creds-gcr"
,
"registry-creds-gcr"
,
map
[
string
]
string
{
map
[
string
]
string
{
"application_default_credentials.json"
:
gcrApplicationDefaultCredentials
,
"application_default_credentials.json"
:
gcrApplicationDefaultCredentials
,
"gcrurl"
:
gcrURL
,
"gcrurl"
:
gcrURL
,
},
},
map
[
string
]
string
{
map
[
string
]
string
{
"app"
:
"registry-creds"
,
"app"
:
"registry-creds"
,
"cloud"
:
"gcr"
,
"cloud"
:
"gcr"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
})
})
...
@@ -142,8 +142,8 @@ var addonsConfigureCmd = &cobra.Command{
...
@@ -142,8 +142,8 @@ var addonsConfigureCmd = &cobra.Command{
"DOCKER_PRIVATE_REGISTRY_PASSWORD"
:
dockerPass
,
"DOCKER_PRIVATE_REGISTRY_PASSWORD"
:
dockerPass
,
},
},
map
[
string
]
string
{
map
[
string
]
string
{
"app"
:
"registry-creds"
,
"app"
:
"registry-creds"
,
"cloud"
:
"dpr"
,
"cloud"
:
"dpr"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
"kubernetes.io/minikube-addons"
:
"registry-creds"
,
})
})
...
...
pkg/minikube/config/config_test.go
浏览文件 @
118e9cc0
...
@@ -47,10 +47,10 @@ var configTestCases = []configTestCase{
...
@@ -47,10 +47,10 @@ var configTestCases = []configTestCase{
"vm-driver": "kvm"
"vm-driver": "kvm"
}`
,
}`
,
config
:
map
[
string
]
interface
{}{
config
:
map
[
string
]
interface
{}{
"vm-driver"
:
"kvm"
,
"vm-driver"
:
"kvm"
,
"cpus"
:
4
,
"cpus"
:
4
,
"disk-size"
:
"20g"
,
"disk-size"
:
"20g"
,
"v"
:
5
,
"v"
:
5
,
"show-libmachine-logs"
:
true
,
"show-libmachine-logs"
:
true
,
"log_dir"
:
"/etc/hosts"
,
"log_dir"
:
"/etc/hosts"
,
"ReminderWaitPeriodInHours"
:
99
,
"ReminderWaitPeriodInHours"
:
99
,
...
...
pkg/minikube/service/service_test.go
浏览文件 @
118e9cc0
...
@@ -258,30 +258,30 @@ func TestOptionallyHttpsFormattedUrlString(t *testing.T) {
...
@@ -258,30 +258,30 @@ func TestOptionallyHttpsFormattedUrlString(t *testing.T) {
expectedIsHTTPSchemedURL
bool
expectedIsHTTPSchemedURL
bool
}{
}{
{
{
description
:
"no https for http schemed with no https option"
,
description
:
"no https for http schemed with no https option"
,
bareURLString
:
"http://192.168.99.100:30563"
,
bareURLString
:
"http://192.168.99.100:30563"
,
https
:
false
,
https
:
false
,
expectedHTTPSFormattedURLString
:
"http://192.168.99.100:30563"
,
expectedHTTPSFormattedURLString
:
"http://192.168.99.100:30563"
,
expectedIsHTTPSchemedURL
:
true
,
expectedIsHTTPSchemedURL
:
true
,
},
},
{
{
description
:
"no https for non-http schemed with no https option"
,
description
:
"no https for non-http schemed with no https option"
,
bareURLString
:
"xyz.http.myservice:30563"
,
bareURLString
:
"xyz.http.myservice:30563"
,
https
:
false
,
https
:
false
,
expectedHTTPSFormattedURLString
:
"xyz.http.myservice:30563"
,
expectedHTTPSFormattedURLString
:
"xyz.http.myservice:30563"
,
expectedIsHTTPSchemedURL
:
false
,
expectedIsHTTPSchemedURL
:
false
,
},
},
{
{
description
:
"https for http schemed with https option"
,
description
:
"https for http schemed with https option"
,
bareURLString
:
"http://192.168.99.100:30563"
,
bareURLString
:
"http://192.168.99.100:30563"
,
https
:
true
,
https
:
true
,
expectedHTTPSFormattedURLString
:
"https://192.168.99.100:30563"
,
expectedHTTPSFormattedURLString
:
"https://192.168.99.100:30563"
,
expectedIsHTTPSchemedURL
:
true
,
expectedIsHTTPSchemedURL
:
true
,
},
},
{
{
description
:
"no https for non-http schemed with https option and http substring"
,
description
:
"no https for non-http schemed with https option and http substring"
,
bareURLString
:
"xyz.http.myservice:30563"
,
bareURLString
:
"xyz.http.myservice:30563"
,
https
:
true
,
https
:
true
,
expectedHTTPSFormattedURLString
:
"xyz.http.myservice:30563"
,
expectedHTTPSFormattedURLString
:
"xyz.http.myservice:30563"
,
expectedIsHTTPSchemedURL
:
false
,
expectedIsHTTPSchemedURL
:
false
,
},
},
...
...
pkg/util/crypto.go
浏览文件 @
118e9cc0
...
@@ -50,7 +50,7 @@ func GenerateCACert(certPath, keyPath string, name string) error {
...
@@ -50,7 +50,7 @@ func GenerateCACert(certPath, keyPath string, name string) error {
KeyUsage
:
x509
.
KeyUsageKeyEncipherment
|
x509
.
KeyUsageDigitalSignature
|
x509
.
KeyUsageCertSign
,
KeyUsage
:
x509
.
KeyUsageKeyEncipherment
|
x509
.
KeyUsageDigitalSignature
|
x509
.
KeyUsageCertSign
,
ExtKeyUsage
:
[]
x509
.
ExtKeyUsage
{
x509
.
ExtKeyUsageClientAuth
,
x509
.
ExtKeyUsageServerAuth
},
ExtKeyUsage
:
[]
x509
.
ExtKeyUsage
{
x509
.
ExtKeyUsageClientAuth
,
x509
.
ExtKeyUsageServerAuth
},
BasicConstraintsValid
:
true
,
BasicConstraintsValid
:
true
,
IsCA
:
true
,
IsCA
:
true
,
}
}
return
writeCertsAndKeys
(
&
template
,
certPath
,
priv
,
keyPath
,
&
template
,
priv
)
return
writeCertsAndKeys
(
&
template
,
certPath
,
priv
,
keyPath
,
&
template
,
priv
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录