Commit Graph

319 Commits

Author SHA1 Message Date
Walter Fender
f3f46d5f5a Moving the cloudprovider interface to staging.
Individual implementations are not yet being moved.
Fixed all dependencies which call the interface.
Fixed golint exceptions to reflect the move.
Added project info as per @dims and
https://github.com/kubernetes/kubernetes-template-project.
Added dims to the security contacts.
Fixed minor issues.
Added missing template files.
Copied ControllerClientBuilder interface to cp.
This allows us to break the only dependency on K8s/K8s.
Added TODO to ControllerClientBuilder.
Fixed GoDeps.
Factored in feedback from JustinSB.
2018-10-04 14:41:20 -07:00
k8s-ci-robot
5dd78df7da
Merge pull request #68982 from aruneli/master
Fixes #65869 Do not listen insecurely if secure port is specified
2018-10-03 17:32:28 -07:00
Arun
1761031f5f Fixes #65869 Do not listen insecurely if secure port is specified 2018-09-25 19:06:34 -07:00
tanshanshan
fdfcc181bf add version to cloud-controller 2018-09-17 08:58:14 +08:00
Kubernetes Submit Queue
a6eb49f0dc
Merge pull request #68195 from luxas/consolidate_componentconfig_code_standards
Automatic merge from submit-queue (batch tested with PRs 67950, 68195). If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

Consolidate componentconfig code standards

**What this PR does / why we need it**:

This PR fixes a bunch of very small misalignments in ComponentConfig packages:
 - Add sane comments to all functions/variables in componentconfig `register.go` files
 - Make the `register.go` files of componentconfig pkgs follow the same pattern and not differ from each other like they do today.
 - Register the `openapi-gen` tag in all `doc.go` files where the pkg contains _external_ types.
 - Add the `groupName` tag where missing
 - Fix cases where `addKnownTypes` was registered twice in the `SchemeBuilder`
 - Add `Readme` and `OWNERS` files to `Godeps` directories if missing.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:


**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/assign @sttts @thockin
2018-09-07 11:19:40 -07:00
Davanum Srinivas
95c70ff6f0
conversion-gen issues with import that are exactly the same
Technically we don't need this. the instruction below:
```
// +k8s:conversion-gen=k8s.io/kubernetes/pkg/controller/apis/config/v1alpha1
```
registers the apiserver/apimachinery packages in the "package universe"
of the conversion-gen program per comment from lucas in PR 68233

However it looks like some files that use both packages run into trouble
and causes failures in CI harness. Attempting here to see if we fix the
order by specifying them explicitly helps.

Change-Id: I20e9c9256f0b7ffdf4e2101d0ca1fe5090e51344
2018-09-06 09:51:54 -04:00
Lucas Käldström
83d53ea1c2
Standardize componentconfig code/comment patterns 2018-09-06 13:42:02 +03:00
Lucas Käldström
c6466b2343
Start using the new packages in the ccm 2018-09-05 14:02:41 +03:00
Lucas Käldström
7e10810ed0
Move CloudControllerManagerConfiguration from pkg/apis/componentconfig to cmd/cloud-controller-manager/app/apis/config 2018-09-05 14:02:25 +03:00
Lucas Käldström
b17d7bf9b3
autogenerated 2018-09-02 14:11:11 +03:00
Lucas Käldström
8aaa527d35
Fixup cmd/*controller-manager code after struct changes. Co-authored by @stewart-yu 2018-09-02 14:10:46 +03:00
Dr. Stefan Schimanski
c609df0ed1 cloud-controller-manager: disable authn/z on insecure port
This is the old behaviour and we did not intent to change it due to enabled authn/z in general.
As the kube-apiserver this sets the "system:unsecured" user info.
2018-08-31 21:19:29 +02:00
Dr. Stefan Schimanski
f6b0c9359b controller-managers: generalize authn/z test to cloud-controller-manager 2018-08-31 20:52:22 +02:00
Dr. Stefan Schimanski
c9913269a6 cloud-controller-manager: add test server 2018-08-31 20:52:22 +02:00
Dr. Stefan Schimanski
88035a4599 cloud-controller-manager: enable secure loopback 2018-08-31 20:52:22 +02:00
Dr. Stefan Schimanski
b25a551ed8 cloud-controller-manager: enable delegated authz/authn if secure port is enabled 2018-08-31 20:52:22 +02:00
Dr. Stefan Schimanski
f35c3f1836 cloud-controller-manager: enable secure ports 10258, deprecate insecure port 2018-08-31 20:52:22 +02:00
Kubernetes Submit Queue
b315ecfe67
Merge pull request #67362 from stewart-yu/stewart-controller-manager-codeclean#02
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

*-controller-manager: output flags in logical sections

![image](https://user-images.githubusercontent.com/30410021/44071436-8e619e72-9fbb-11e8-84c5-72c1ff9767b6.png)

```
Print *-controller-manager --help flag help in sections.
```
2018-08-27 07:31:08 -07:00
Davanum Srinivas
9b43d97cd4
Add Labels to various OWNERS files
Will reduce the burden of manually adding labels. Information pulled
from:
https://github.com/kubernetes/community/blob/master/sigs.yaml

Change-Id: I17e661e37719f0bccf63e41347b628269cef7c8b
2018-08-21 13:59:08 -04:00
Nikhita Raghunath
6e47ba1fde Add sig/api-machinery label to apimachinery OWNERS files 2018-08-20 18:46:47 +05:30
stewart-yu
b0eb92cc52 auto-generated file 2018-08-20 20:03:37 +08:00
stewart-yu
a14673cfbd [cloud-controller-manager]output flags in logical sections 2018-08-20 20:03:36 +08:00
Dr. Stefan Schimanski
c2724793e8 Update bazel 2018-08-17 08:57:21 +02:00
Dr. Stefan Schimanski
1d9a896066 apiserver: move controller-manager's insecure config into apiserver 2018-08-17 08:56:46 +02:00
Kubernetes Submit Queue
108bc499b7
Merge pull request #67358 from stewart-yu/stewart-controller-manager-codeclean
Automatic merge from submit-queue (batch tested with PRs 67347, 67307, 67358, 67364, 67385). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

*-controller-manager: remove the redundancy import file

**What this PR does / why we need it**:
remove the redundancy import file

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:
remove the redundancy import file @deads2k  @mikedanese 

**Release note**:

```release-note
NONE
```
2018-08-15 04:23:18 -07:00
Lucas Käldström
db855a2b2d
autogenerated 2018-08-14 19:02:18 +03:00
Lucas Käldström
4bef926218
Remove references to the config structs that have moved to their own shared packages 2018-08-14 19:02:06 +03:00
stewart-yu
9f4ae6ddf6 [cloud-controller manager]remove the redundancy import 2018-08-14 14:08:06 +08:00
David Eads
fb7d137ea2 add debug handler capability for individual controllers 2018-07-26 13:24:36 -04:00
Kubernetes Submit Queue
7786bd8c9a
Merge pull request #64654 from atlassian/missing-error-handling
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Add missing error handling in schema-related code

**What this PR does / why we need it**:
Adds missing error handling to a few places.

**Which issue(s) this PR fixes**
Updates #51457. Still more work to do to fix the issue - client generation code needs to be updated (addressed in https://github.com/kubernetes/kubernetes/pull/64664).

**Release note**:
```release-note
NONE
```

/kind bug
/sig api-machinery
2018-07-02 07:14:34 -07:00
Kubernetes Submit Queue
67e7d4c68f
Merge pull request #65399 from stewart-yu/stewart-cloudcontroller-manager-reviewer
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

add myself to cmd/[cloud-]controller-manage reviewer

**What this PR does / why we need it**:
add myself to `cmd/cloud-controller-manage` reviewer

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-06-25 03:43:19 -07:00
Mikhail Mazurskiy
bfe313d5f3
Add missing error handling in schema-related code 2018-06-23 21:06:32 +10:00
stewart-yu
92b8fd5dbd add myself to cmd/[cloud-]controller-manage reviewer 2018-06-23 12:46:50 +08:00
Jeff Grafton
23ceebac22 Run hack/update-bazel.sh 2018-06-22 16:22:57 -07:00
stewart-yu
dfdfd68b7a auto-generated file 2018-06-21 20:16:27 +08:00
stewart-yu
e9296b50f3 [cloud-controller manager]move more setup code from startControllers into the config 2018-06-21 19:28:52 +08:00
Mikhail Mazurskiy
102090d1f1
Use context.TODO() to be explicit that cancellation is not implemented 2018-06-07 14:33:03 +10:00
Mikhail Mazurskiy
dc32a341c0
Cancellable leader election with context 2018-06-07 14:24:02 +10:00
Mikhail Mazurskiy
1d99fff1ac
Cancellable leader election with channels 2018-06-07 14:24:01 +10:00
Kubernetes Submit Queue
0340864ae9
Merge pull request #64016 from stewart-yu/stewart-controller-manager-codeclean
Automatic merge from submit-queue (batch tested with PRs 57082, 64325, 64016, 64443, 64403). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

should not ignore err when convert api version

**What this PR does / why we need it**:
should not ignore err when convert api version

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-05-30 18:49:17 -07:00
stewart-yu
be7f087ade do some code clean for cloud-controller manager 2018-05-23 17:28:02 +08:00
stewart-yu
956bbfd1a6 should not ignore err when convert controllermanagerconfiguration api 2018-05-23 13:14:04 +08:00
stewart-yu
3d20f1a99c auto generated file 2018-05-18 10:23:38 +08:00
stewart-yu
14f7b959ff modify cloud-controller manager config struct to adapt option change 2018-05-18 10:23:38 +08:00
stewart-yu
2a8d258f66 [cloud-controller manager]get rid of GenericControllerManagerOptions sub-struct 2018-05-18 10:23:38 +08:00
xuzhonghu
7e894b33ee pass stop channel to node-controller 2018-05-15 17:08:35 +08:00
Kubernetes Submit Queue
74c6632c97
Merge pull request #62749 from andrewsykim/ccm-approvers
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

add @andrewsykim to OWNERS for cmd/cloud-controller-manager,pkg/contr…

**What this PR does / why we need it**:
Add myself as an approver for CCM related code.

cc @wlan0 

**Release note**:
```release-note
Add @andrewsykim as an approver for CCM related code.
```
2018-04-17 15:14:50 -07:00
andrewsykim
da06951013 add @andrewsykim to OWNERS for cmd/cloud-controller-manager,pkg/controller/cloud,pkg/cloudprovider 2018-04-17 16:43:58 -04:00
Kubernetes Submit Queue
0f3de97db9
Merge pull request #60270 from stewart-yu/splitFlag
Automatic merge from submit-queue (batch tested with PRs 61306, 60270, 62496, 62181, 62234). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

split up the huge set of flags into smaller option structs

**What this PR does / why we need it**:
To make generic, we do following work:

1.  Spliting `KubeControllerManagerConfiguration` in kube-controller-manager and cloud-controller-manager into fewer smaller struct options order by controller, and modify relative flag. Also part of #59483.
2. Spliting `componentconfig` in controller-manager into fewer smaller config order by controller too.

All works follow #59582, using `option+config` logic.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-04-13 15:03:07 -07:00
stewart-yu
ea376c9c6f auto generated file 2018-04-13 08:57:40 +08:00
stewart-yu
ec6399be53 split up the component config into smaller config 2018-04-13 08:40:54 +08:00
stewart-yu
75e39073a3 split KubeControllerManagerConfiguration into fewer options struct 2018-04-13 08:40:54 +08:00
Kubernetes Submit Queue
60c6d0e0ba
Merge pull request #60197 from hzxuzhonghu/controller-manager-handler-chain
Automatic merge from submit-queue (batch tested with PRs 60197, 61614, 62074, 62071, 62301). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Refactor controller-manager: turn Serve func into handlerchain builder

**What this PR does / why we need it**:
follow up #59582 fix
> turn Serve func into a handler chain builder https://github.com/kubernetes/kubernetes/pull/59582#discussion_r167258465

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-04-10 08:56:15 -07:00
hzxuzhonghu
c6e74da162 update bazel 2018-03-31 17:01:51 +08:00
hzxuzhonghu
281b7f3b41 remove usless arguments of startControllers 2018-03-31 14:26:40 +08:00
Davanum Srinivas
ba2778b17a Set leader-elect for kube-scheduler to true
Thanks to some great sleuthing by ikruglov!

kube-controller-manager defaults --leader-elect to true. We should
do the same for kube-scheduler. kube-scheduler used to have this
set to true, but it got lost during refactoring in:
efb2bb71cd
2018-03-30 10:52:01 -04:00
Chao Wang
95f99bf323 remove --service-account-private-key-file in v1.11 2018-03-07 17:10:28 +08:00
hzxuzhonghu
540a1de161 Refactor controller-manager: turn Serve func into handlerchain builder 2018-03-06 09:37:25 +08:00
Kubernetes Submit Queue
b8c5bcf48a
Merge pull request #60291 from hzxuzhonghu/cloud-cm-use-healthz
Automatic merge from submit-queue (batch tested with PRs 60376, 55584, 60358, 54631, 60291). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

cloud-controller-manager get /healthz to wait for apiserver to be healthy

**What this PR does / why we need it**:

currently cloud-controller-manager use `restclient.ServerAPIVersions()` to wait for apiserver to be healthy.
Remove ServerAPIVersions and make use of /healthz as all other components do.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #60288

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2018-02-28 03:37:37 -08:00
hzxuzhonghu
97be082fb1 cloud-controller-manager get /healthz instead of calling restclient.ServerAPIVersions to wait for apiserver being healthy 2018-02-28 17:24:59 +08:00
Kubernetes Submit Queue
3c2a0c84c5
Merge pull request #60054 from MikeSpreitzer/issue-60042-field
Automatic merge from submit-queue (batch tested with PRs 60054, 60202, 60219, 58090, 60275). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fixes for HTTP/2 max streams per connection setting

**What this PR does / why we need it**:
This PR makes two changes.  One is to introduce a parameter
for the HTTP/2 setting that an api-server sends to its clients
telling them how many streams they may have concurrently open in
an HTTP/2 connection.  If left at its default value of zero,
this means to use the default in golang's HTTP/2 code (which
is currently 250; see https://github.com/golang/net/blob/master/http2/server.go).

The other change is to make the recommended options for an aggregated
api-server set this limit to 1000.  The limit of 250 is annoyingly low
for the use case of many controllers watching objects of Kinds served
by an aggregated api-server reached through the main api-server (in
its mode as a proxy for the aggregated api-server, in which it uses a
single HTTP/2 connection for all calls proxied to that aggregated
api-server).

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #60042

**Special notes for your reviewer**:

**Release note**:

```release-note
Introduced `--http2-max-streams-per-connection` command line flag on api-servers and set default to 1000 for aggregated API servers.
```
2018-02-23 23:15:33 -08:00
Mike Spreitzer
201c11f147 Fixes for HTTP/2 max streams per connection setting
This PR makes two changes.  One is to introduce a parameter
for the HTTP/2 setting that an api-server sends to its clients
telling them how many streams they may have concurrently open in
an HTTP/2 connection.  If left at its default value of zero,
this means to use the default in golang's HTTP/2 code (which
is currently 250).

The other change is to make the recommended options for an aggregated
api-server set this limit to 1000.  The limit of 250 is annoyingly low
for the use case of many controllers watching objects of Kinds served
by an aggregated api-server reached through the main api-server (in
its mode as a proxy for the aggregated api-server, in which it uses a
single HTTP/2 connection for all calls proxied to that aggregated
api-server).

Fixes #60042
2018-02-22 16:31:21 -05:00
hzxuzhonghu
398a0a9e66 update bazel 2018-02-22 16:43:13 +08:00
Kubernetes Submit Queue
96ec318718
Merge pull request #59842 from ixdy/update-rules_go-02-2018
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

 Update bazelbuild/rules_go, kubernetes/repo-infra, and gazelle dependencies

**What this PR does / why we need it**: updates our bazelbuild/rules_go dependency in order to bump everything to go1.9.4. I'm separating this effort into two separate PRs, since updating rules_go requires a large cleanup, removing an attribute from most build rules.

**Release note**:

```release-note
NONE
```
2018-02-19 22:23:05 -08:00
Jeff Grafton
ef56a8d6bb Autogenerated: hack/update-bazel.sh 2018-02-16 13:43:01 -08:00
Davanum Srinivas
265e5ae085 Log the command line flags
With d7ddcca231, we lost the logging
of the flags. We should at least log what the command line flags
were used to start processes as those incredibly useful for trouble shooting.
2018-02-15 18:04:04 -05:00
Dr. Stefan Schimanski
5483ab7679 Update generated files 2018-02-13 11:16:48 +01:00
Dr. Stefan Schimanski
f4564ea0b8 controller-manager: add SecureServingOptions 2018-02-13 11:16:47 +01:00
stewart-yu
0cbe0a6034 controller-manager: switch to config/option struct pattern 2018-02-13 11:16:17 +01:00
Khaled Henidak(Kal)
f9c8d7de9c auto generated items
remove ServiceSyncPeriod from tests

fixing tests
2018-02-07 03:26:51 +00:00
David Eads
25238441fd uniquify resource lock identities 2018-01-18 11:31:43 -05:00
David Eads
d7ddcca231 low hanging fruit for using cobra commands 2018-01-17 13:43:43 -05:00
Cao Shufeng
4e7398b67b remove duplicated import 2018-01-17 09:34:59 +08:00
Kubernetes Submit Queue
f4bfcba0c8
Merge pull request #56411 from supereagle/authentication-client-with-version
Automatic merge from submit-queue (batch tested with PRs 57651, 56411, 56779, 57523, 57624). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use authentication client with explicit version

**What this PR does / why we need it**:
Authentication client without explicit version has been deprecated, change them to the one with explicit version.

**Which issue(s) this PR fixes**:
Fixes partially #55993

**Special notes for your reviewer**:
/cc @caesarxuchao @sttts

**Release note**:
```release-note
NONE
```
2018-01-02 14:09:43 -08:00
Jeff Grafton
46e894bfd3 Switch go binaries from (hacky) static to pure Go 2017-12-23 13:13:09 -08:00
Jeff Grafton
efee0704c6 Autogenerate BUILD files 2017-12-23 13:12:11 -08:00
Walter Fender
070a7b5823 Seperate loop and plugin control
Seperate loop and plugin control in the kube-controller-manager.
Adding an "--external-plugin" flag to specify a plugin to load when
cloud-provider is set to "external". Flag has no effect currently
when the cloud-provider is not set to external. The expectation is
that the cloud provider and external plugin flags would go away once
all cloud providers are on stage 2 cloud-controller-manager solutions.

Managing the control loops more directly based on start up flags.
Addressing issue brought up by @wlan0

Switched to using the main node controller in CCM.
Changes to enable full NodeController to start in CCM.
Fix related tests.
Unifying some common code between KCM and CCM.
Fix related tests and comments.
Folded in feedback from @jhorwit2 and @wlan0
2017-12-18 10:58:45 -08:00
Kubernetes Submit Queue
3e2de4e427
Merge pull request #56828 from oracle/for/upstream/master/ccm-lock-id
Automatic merge from submit-queue (batch tested with PRs 56828, 55184, 56849, 57081, 56654). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Use hostname for CCM resource lock id

**What this PR does / why we need it**:

Uses the hostname for the resource lock id without the `-external-cloud-controller` which follows how the kube-scheduler and KCM select their ID. This is useful for tools that use the id to fetch logs from the leader among other things. 

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @wlan0 @luxas
2017-12-16 17:45:38 -08:00
Kubernetes Submit Queue
e1ee105bba
Merge pull request #56410 from stewart-yu/cloudeprovider-fixcloudnil
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

If cloud==nil, it should exits to avoid Panic

**What this PR does / why we need it**:
If `cloud == nil`, it should exits, otherwise `cloud.HasClusterID()` will panic.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-12-16 04:11:02 -08:00
Josh Horwitz
def22b796c Use hostname for CCM resource lock id 2017-12-04 21:52:33 -05:00
supereagle
7dce7fe1eb use authentication client with explicit version 2017-11-27 22:13:19 +08:00
stewart-yu
eed826a25e fix bug when cloud is nil 2017-11-27 21:55:32 +08:00
stewart-yu
26626529a7 should check return err 2017-11-26 11:03:14 +08:00
Kai Chen
81bf0265c9 Fix typo in CloudControllerManager 2017-11-15 22:17:55 -08:00
Kubernetes Submit Queue
b2625857ad
Merge pull request #54197 from colemickens/hyperkube-add-cloud-controller-manager
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

hyperkube: add cloud-controller-manager

**What this PR does / why we need it**:

Adds `cloud-controller-manager` to `hyperkube`. (fix #55732)

This is useful as a number of deployment tools run all of the kubernetes components from the `hyperkube` image/binary. It also makes testing easier as a single binary/image can be built and pushed quickly.

This PR follows the same pattern of the other kubernetes binaries being available as part of `hyperkube`.

(This PR also makes an error condition appropriately fatal.)

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: n/a

**Special notes for your reviewer**: n/a

**Release note**:

```release-note
hyperkube: add cloud-controller-manager
```

/sig cluster-lifecycle
/area cloudprovider
2017-11-15 00:48:32 -08:00
Josh Horwitz
a1fddf48c5 Add concurrent service sync flag to CCM 2017-11-12 14:29:47 -05:00
Cole Mickens
1675f025ea ccm: make missing --cloud-provider fatal 2017-11-10 14:28:58 -08:00
Cole Mickens
91dc0ca339 hyperkube: add cloud-controller-manager 2017-11-10 14:28:58 -08:00
Cole Mickens
976cf098dd ccm: move all argument handling to server 2017-11-10 14:28:58 -08:00
Josh Horwitz
590e626939 Add support for configmap resource lock type to CCM 2017-11-05 19:24:16 -05:00
Dr. Stefan Schimanski
cad0364e73 Update bazel 2017-10-18 17:24:04 +02:00
Dr. Stefan Schimanski
7773a30f67 pkg/api/legacyscheme: fixup imports 2017-10-18 17:23:55 +02:00
Jeff Grafton
aee5f457db update BUILD files 2017-10-15 18:18:13 -07:00
drinktee
c630a41017 add unit test for cloud-controller-manager 2017-10-15 10:29:46 +08:00
tcharding
cd13ab0f69 cmd: cloud-controller: remove golint_failures entry 2017-10-05 14:19:59 +11:00
Andrew Pryde
cb4c822e82 All cloud-providers not required out-of-tree
Note that importing all cloud-providers is not required when
implementing an out-of-tree cloud-provider.
2017-09-27 15:31:15 +01:00
Kubernetes Submit Queue
19af5de8cd Merge pull request #52633 from karataliu/ccm_defaultrrp
Automatic merge from submit-queue (batch tested with PRs 52751, 52898, 52633, 52611, 52609). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>..

Add default value for RouteReconciliationPeriod in cloud controller manager

**What this PR does / why we need it**:
Add default sync period value config for RouteReconciliationPeriod. For now the default value is 0, which means zero cooldown time.

The value is taken from kube-controller-manager:
b2b079b95a/cmd/kube-controller-manager/app/options/options.go (L73)

**Which issue this PR fixes**

**Special notes for your reviewer**:

**Release note**:
2017-09-24 05:27:50 -07:00
Kubernetes Submit Queue
cb0ee6f295 Merge pull request #52406 from wackxu/rminithea
Automatic merge from submit-queue (batch tested with PRs 50068, 52406, 52394, 48551, 52131). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>..

remove unless healthz.DefaultHealthz() in controller-manager

**What this PR does / why we need it**:

remove unless healthz.DefaultHealthz() in controller-manager

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #52405

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-09-23 20:55:46 -07:00
Dong Liu
5af2ac5344 Add comment for controller manager default values 2017-09-20 15:53:22 +08:00
Dong Liu
7f52438dea Add default value for RouteReconciliationPeriod in cloud controller manager 2017-09-18 13:17:14 +08:00
Dong Liu
a53b0c3f34 Add cluster name option for cloud controller manager 2017-09-15 14:00:06 +08:00
wackxu
2070aa6b1f remove unless healthz.DefaultHealthz() in controller-manager 2017-09-13 16:40:14 +08:00
Kubernetes Submit Queue
a4b7100c20 Merge pull request #52007 from oracle/for/upstream/master/ccm-sa-run-jitter
Automatic merge from submit-queue (batch tested with PRs 52007, 52196, 52169, 52263, 52291)

Fixed CCM service controller start jitter

**What this PR does / why we need it**: The start jitter for the service controller was running regardless if the service controller was being ran. This should help startup time for CCM's without the service controller implementation. 

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/cc @wlan0 @andrewsykim @luxas @jhorwit2

/area cloudprovider
/sig cluster-lifecycle
2017-09-12 08:46:05 -07:00
Kubernetes Submit Queue
ae8780f5ce Merge pull request #50289 from liggitt/cloud-controller-manager
Automatic merge from submit-queue (batch tested with PRs 50289, 52106)

Honor --use-service-account-credentials in cloud-controller-manager

If --use-service-account-credentials is specified, the cloud controller manager should honor it

The distinction between the rootclientbuilder and the clientbuilder came from kube-controller-manager, which is responsible for running the very controllers that enable service accounts. That two-layer approach is not needed in the cloud-controller-manager.

```release-note
The `kube-cloud-controller-manager` flag `--service-account-private-key-file` was non-functional and is now deprecated.
The `kube-cloud-controller-manager` flag `--use-service-account-credentials` is now honored consistently, regardless of whether `--service-account-private-key-file` was specified.
```
2017-09-12 03:44:15 -07:00
Josh Horwitz
b286f9fdac Fixed CCM service controller start jitter 2017-09-06 09:23:02 +01:00
Kubernetes Submit Queue
43a40f7ab5 Merge pull request #44680 from rrati/pvl-controller
Automatic merge from submit-queue (batch tested with PRs 51574, 51534, 49257, 44680, 48836)

Add a persistent volume label controller to the cloud-controller-manager

Part of https://github.com/kubernetes/features/issues/88

Outstanding concerns needing input:
- [x] Why 5 threads for controller processing?
- [x] Remove direct linkage to aws/gce cloud providers [#51629]
- [x] Modify shared informers to allow added event handlers ability to include uninitialized objects/using unshared informer #48893
- [x] Use cache.MetaNamespaceKeyFunc in event handler?

I'm willing to work on addressing the removal of the direct linkage to aws/gce after this PR gets in.
2017-08-31 23:13:23 -07:00
wackxu
c69df736ee refactor function 2017-08-30 17:09:12 +08:00
Kubernetes Submit Queue
cbfb500836 Merge pull request #51510 from drinktee/master
Automatic merge from submit-queue (batch tested with PRs 51298, 51510, 51511)

Add some periods in cloud controller manager's options

Add some periods in cloud controller manager's options
2017-08-29 10:38:16 -07:00
chenguoyan01
f2c530ee79 fix extra blanks in cloud controller manager's options 2017-08-29 19:44:23 +08:00
chenguoyan01
7062b977b7 add some period in cloud controller manager's options 2017-08-29 16:54:37 +08:00
Robert Rati
53856420e8 Replicate the persistent volume label admission plugin in a controller in
the cloud-controller-manager
2017-08-28 03:12:18 -04:00
devinyan
96c6bc5d91 modify an little gammer error. 2017-08-25 23:16:05 +08:00
wlan0
92415f7dd7 Proposal to add @wlan0 to appropriate owner files 2017-08-17 11:37:51 -07:00
Jordan Liggitt
55c7ce1d80
Honor --use-service-account-credentials in cloud-controller-manager 2017-08-17 01:41:57 -04:00
Jeff Grafton
a7f49c906d Use buildozer to delete licenses() rules except under third_party/ 2017-08-11 09:32:39 -07:00
Jeff Grafton
33276f06be Use buildozer to remove deprecated automanaged tags 2017-08-11 09:31:50 -07:00
Robert Rati
926f070719 Make ClusterID required for AWS. #48954 2017-08-07 15:47:00 -04:00
supereagle
edce96c5b6 use the core client with version 2017-07-26 19:16:02 +08:00
supereagle
adc0eef43e remove duplicated import and wrong alias name of api package 2017-07-25 10:04:25 +08:00
Clayton Coleman
b9bebe8a4e
Use a client interface instead of a concrete type
Aids testing
2017-07-22 20:29:48 -04:00
Kubernetes Submit Queue
96f7788f78 Merge pull request #48797 from FengyunPan/fix-empty-cidr
Automatic merge from submit-queue (batch tested with PRs 48231, 47377, 48797, 49020, 49033)

Fix parsing empty CIDR

Fix #48795
Checking ClusterCIDR and ServiceCIDR before parsing them.

**Release note**:
```release-note
NONE
```
2017-07-17 19:37:45 -07:00
Jacob Simpson
29c1b81d4c Scripted migration from clientset_generated to client-go. 2017-07-17 15:05:37 -07:00
FengyunPan
dfc8b667a2 Fix parsing empty CIDR
Fix #48795
Checking ClusterCIDR and ServiceCIDR before parsing them.
2017-07-13 21:08:43 +08:00
Chao Xu
65cedeeb43 update bazel 2017-07-07 19:04:26 -07:00
Chao Xu
56de7e702e obvious fix 2017-07-07 19:04:26 -07:00
Chao Xu
24d5279c59 move leaderelection package to client-go 2017-07-07 17:01:04 -07:00
Kubernetes Submit Queue
f663c4c83e Merge pull request #47489 from Mashimiao/cm-remove-unneeded
Automatic merge from submit-queue (batch tested with PRs 48264, 48324, 48125, 47944, 47489)

remove unneeded variable

Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>



**What this PR does / why we need it**:
small fix, remove unneeded variable

**Release note**:

```release-note
NONE
```
2017-06-30 20:58:35 -07:00
Chao Xu
60604f8818 run hack/update-all 2017-06-22 11:31:03 -07:00
Chao Xu
f2d3220a11 run root-rewrite-import-client-go-api-types 2017-06-22 11:30:59 -07:00
Ma Shimiao
ec3bbf733d remove unneeded variable
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
2017-06-14 11:54:23 +08:00
Jeff Grafton
64bd79fad7 Convert go_binary linkstamp to x_defs 2017-06-08 14:59:55 -07:00
Nick Sardo
87a5edd2cd Initialize cloud providers with a K8s clientBuilder 2017-05-17 14:38:25 -07:00
Sidhartha Mani
8666eaac53 bug fix #45156. Make cloud-provider flag mandatory 2017-05-05 16:51:49 -07:00
wlan0
45d2bc06b7 cloud initialize node in external cloud controller 2017-05-05 16:51:45 -07:00
Mike Danese
3757e8bb5c bazel: statically link dockerized components
and remove libc from docker images when it's not needed.
2017-04-14 15:51:54 -07:00
Mike Danese
a05c3c0efd autogenerated 2017-04-14 10:40:57 -07:00
garyyu(于广游)
c9535869fc Bugfix: cloud-controller-manager routeController.run() block in WaitForCacheSync 2017-04-12 13:03:41 +08:00
NickrenREN
1dc323a8f9 remove NewCloudNodeController() second return value
NewCloudNodeController() will never return err,remove it
2017-03-25 10:54:01 +08:00
Andy Goldstein
b011529d8a Add pprof trace support
Add pprof trace support and --enable-contention-profiling to those
components that don't already have it.
2017-03-07 10:10:42 -05:00
Andy Goldstein
171e458bab Update bazel 2017-02-27 06:48:13 -05:00
Andy Goldstein
4cd38b863f Remove references to pkg/controller/informers 2017-02-27 06:47:59 -05:00
Kubernetes Submit Queue
af41d2f57c Merge pull request #41661 from liggitt/satoken
Automatic merge from submit-queue

Make controller-manager resilient to stale serviceaccount tokens

Now that the controller manager is spinning up controller loops using service accounts, we need to be more proactive in making sure the clients will actually work.

Future additional work:
* make a controller that reaps invalid service account tokens (c.f. https://github.com/kubernetes/kubernetes/issues/20165)
* allow updating the client held by a controller with a new token while the controller is running (c.f. https://github.com/kubernetes/kubernetes/issues/4672)
2017-02-20 08:39:31 -08:00
Jordan Liggitt
b83e6f7d91
Make controller-manager resilient to stale serviceaccount tokens 2017-02-17 23:59:00 -05:00
Andy Goldstein
726f18524b Switch service controller to shared informers 2017-02-15 11:21:01 -05:00
Kubernetes Submit Queue
456b9dc5cc Merge pull request #41346 from ncdc/shared-informers-08-route
Automatic merge from submit-queue (batch tested with PRs 41115, 41212, 41346, 41340, 41172)

Switch route controller to shared informers

Initially part of #40097 

@smarterclayton @gmarek @wojtek-t @timothysc @kubernetes/sig-scalability-pr-reviews @sttts @deads2k @liggitt
2017-02-13 17:03:49 -08:00
Andy Goldstein
effde6b8dd Switch route controller to shared informers 2017-02-13 15:21:33 -05:00
deads2k
78d8a8efa8 copy pkg/util/logs to apiserver 2017-02-13 12:07:15 -05:00
deads2k
fd34b11e13 react to informer updates 2017-02-13 09:18:32 -05:00
deads2k
a86fabb9d2 regenerate informers 2017-02-13 07:59:34 -05:00
Andy Goldstein
70c6087600 Replace hand-written informers with generated ones
Replace existing uses of hand-written informers with generated ones.
 Follow-up commits will switch the use of one-off informers to shared
 informers.
2017-02-06 13:49:27 -05:00
deads2k
8a12000402 move client/record 2017-01-31 19:14:13 -05:00
Dr. Stefan Schimanski
2b8e938128 Update generated files 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski
82826ec273 pkg/util/flag: move to k8s.io/apiserver 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski
a6b2ebb50c pkg/flag: make feature gate extensible and split between generic and kube 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski
56d60cfae6 pkg/util: move flags from pkg/util/config to pkg/util/flags 2017-01-24 20:56:03 +01:00
deads2k
335ef747d6 mechanical 2017-01-23 10:03:55 -05:00
deads2k
ee6752ef20 find and replace 2017-01-20 08:04:53 -05:00
deads2k
c587b8a21e re-run client-gen 2017-01-20 08:02:36 -05:00
Dr. Stefan Schimanski
3d9449a353 genericapiserver: fix imports 2017-01-19 13:06:47 +01:00
Clayton Coleman
9a2a50cda7
refactor: use metav1.ObjectMeta in other types 2017-01-17 16:17:19 -05:00
NickrenREN
a12dea14e0 fix redundant alias clientset 2017-01-12 10:21:05 +08:00
deads2k
6a4d5cd7cc start the apimachinery repo 2017-01-11 09:09:48 -05:00
Kubernetes Submit Queue
73d36ce587 Merge pull request #39394 from wlan0/master
Automatic merge from submit-queue (batch tested with PRs 39394, 38270, 39473, 39516, 36243)

make private method private

@thockin
2017-01-09 12:05:17 -08:00
Jeff Grafton
20d221f75c Enable auto-generating sources rules 2017-01-05 14:14:13 -08:00
deads2k
4d7fcae85a mechanicals 2017-01-05 11:14:27 -05:00
wlan0
3917342bbb make private method private 2017-01-03 15:33:01 -08:00
Mike Danese
161c391f44 autogenerated 2016-12-29 13:04:10 -08:00
wlan0
75da310757 sanitize names and add more comments, and other essential boilerplate changes 2016-12-22 14:37:15 -08:00
wlan0
1e48fd18cb add cloud-controller-manager as the first step in breaking controller-manager 2016-12-22 14:37:15 -08:00