Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Chu Peng 楚鹏
minikube
提交
030a4c74
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,发现更多精彩内容 >>
提交
030a4c74
编写于
12月 18, 2017
作者:
D
dlorenc
提交者:
dlorenc
12月 21, 2017
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Manual changes for 1.9 update.
上级
28cbc6f7
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
24 addition
and
19 deletion
+24
-19
pkg/localkube/proxy.go
pkg/localkube/proxy.go
+12
-12
pkg/localkube/scheduler.go
pkg/localkube/scheduler.go
+8
-4
test/integration/cluster_status_test.go
test/integration/cluster_status_test.go
+1
-1
test/integration/pv_test.go
test/integration/pv_test.go
+3
-2
未找到文件。
pkg/localkube/proxy.go
浏览文件 @
030a4c74
...
...
@@ -23,9 +23,8 @@ import (
"time"
"k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/kubernetes/pkg/apis/componentconfig"
"k8s.io/kubernetes/pkg/kubelet/qos"
"k8s.io/kubernetes/pkg/proxy/apis/kubeproxyconfig"
)
var
(
...
...
@@ -42,34 +41,35 @@ func StartProxyServer(lk LocalkubeServer) func() error {
if
lk
.
APIServerInsecurePort
!=
0
{
bindaddress
=
lk
.
APIServerInsecureAddress
.
String
()
}
config
:=
&
componentconfig
.
KubeProxyConfiguration
{
opts
:=
kubeproxy
.
NewOptions
()
config
:=
&
kubeproxyconfig
.
KubeProxyConfiguration
{
OOMScoreAdj
:
&
OOMScoreAdj
,
ClientConnection
:
component
config
.
ClientConnectionConfiguration
{
ClientConnection
:
kubeproxy
config
.
ClientConnectionConfiguration
{
Burst
:
10
,
QPS
:
5
,
KubeConfigFile
:
util
.
DefaultKubeConfigPath
,
},
ConfigSyncPeriod
:
v1
.
Duration
{
Duration
:
15
*
time
.
Minute
},
IPTables
:
component
config
.
KubeProxyIPTablesConfiguration
{
IPTables
:
kubeproxy
config
.
KubeProxyIPTablesConfiguration
{
MasqueradeBit
:
&
MasqueradeBit
,
SyncPeriod
:
v1
.
Duration
{
Duration
:
30
*
time
.
Second
},
MinSyncPeriod
:
v1
.
Duration
{
Duration
:
5
*
time
.
Second
},
},
BindAddress
:
bindaddress
,
Mode
:
component
config
.
ProxyModeIPTables
,
Mode
:
kubeproxy
config
.
ProxyModeIPTables
,
FeatureGates
:
lk
.
FeatureGates
,
// Disable the healthz check
HealthzBindAddress
:
"0"
,
}
_
,
err
:=
opts
.
ApplyDefaults
(
config
)
if
err
!=
nil
{
panic
(
err
)
}
lk
.
SetExtraConfigForComponent
(
"proxy"
,
&
config
)
return
func
()
error
{
// Creating this config requires the API Server to be up, so do it in the start function itself.
server
,
err
:=
kubeproxy
.
NewProxyServer
(
config
,
false
,
runtime
.
NewScheme
(),
lk
.
GetAPIServerInsecureURL
())
if
err
!=
nil
{
panic
(
err
)
}
return
server
.
Run
()
return
opts
.
Run
()
}
}
pkg/localkube/scheduler.go
浏览文件 @
030a4c74
...
...
@@ -17,8 +17,8 @@ limitations under the License.
package
localkube
import
(
"k8s.io/kubernetes/pkg/apis/componentconfig"
scheduler
"k8s.io/kubernetes/plugin/cmd/kube-scheduler/app"
"k8s.io/kubernetes/plugin/cmd/kube-scheduler/app/options"
"k8s.io/minikube/pkg/util"
)
...
...
@@ -27,10 +27,10 @@ func (lk LocalkubeServer) NewSchedulerServer() Server {
}
func
StartSchedulerServer
(
lk
LocalkubeServer
)
func
()
error
{
config
:=
options
.
NewSchedulerServer
()
config
:=
componentconfig
.
KubeSchedulerConfiguration
{}
// master details
config
.
Kubeconfig
=
util
.
DefaultKubeConfigPath
config
.
ClientConnection
.
KubeConfigFile
=
util
.
DefaultKubeConfigPath
// defaults from command
config
.
EnableProfiling
=
true
...
...
@@ -38,6 +38,10 @@ func StartSchedulerServer(lk LocalkubeServer) func() error {
lk
.
SetExtraConfigForComponent
(
"scheduler"
,
&
config
)
return
func
()
error
{
return
scheduler
.
Run
(
config
)
s
,
err
:=
scheduler
.
NewSchedulerServer
(
&
config
,
""
)
if
err
!=
nil
{
return
err
}
return
s
.
Run
(
nil
)
}
}
test/integration/cluster_status_test.go
浏览文件 @
030a4c74
...
...
@@ -23,7 +23,7 @@ import (
"testing"
"time"
"k8s.io/kubernetes/pkg/api
"
api
"k8s.io/kubernetes/pkg/apis/core
"
"k8s.io/minikube/test/integration/util"
)
...
...
test/integration/pv_test.go
浏览文件 @
030a4c74
...
...
@@ -20,13 +20,14 @@ package integration
import
(
"fmt"
"github.com/pkg/errors"
"path/filepath"
"testing"
"time"
"github.com/pkg/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/kubernetes/pkg/api
"
api
"k8s.io/kubernetes/pkg/apis/core
"
"k8s.io/kubernetes/pkg/apis/storage"
commonutil
"k8s.io/minikube/pkg/util"
"k8s.io/minikube/test/integration/util"
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录