Commit Graph

738 Commits (552a247639f2e426c2533ed78bbaacae096269d2)

Author SHA1 Message Date
k8s-merge-robot d33fa39abf Merge pull request #23254 from jsafrane/devel/ulimited-aws-devices
Automatic merge from submit-queue

AWS: Move enforcement of attached AWS device limit from kubelet to scheduler

Limit of nr. of attached EBS volumes to a node is now enforced by scheduler. It can be adjusted by `KUBE_MAX_PD_VOLS` env. variable there. Therefore we don't need the same check in kubelet. If the system admin wants to attach more, we should allow it.

Kubelet limit is now 650 attached volumes ('ba'..'zz').

Note that the scheduler counts only *pods* assigned to a node. When a pod is deleted and a new pod is scheduled on a node, kubelet start (slowly) detaching the old volume and (slowly) attaching the new volume. Depending on AWS speed **it may happen that more than KUBE_MAX_PD_VOLS volumes are actually attached to a node for some time!** Kubelet will clean it up in few seconds / minutes (both attach/detach is quite slow).

Fixes #22994
2016-05-19 06:13:42 -07:00
dagnello 52811375d1 Adding error check when read instance id failed 2016-05-13 22:18:55 -07:00
k8s-merge-robot 24c46acd16 Merge pull request #24369 from Clarifai/ecr
Automatic merge from submit-queue

AWS: Allow cross-region image pulling with ECR

Fixes #23298
Definitely should be in the release notes; should maybe get merged in 1.2 along with #23594 after some soaking. Documentation changes to follow.

cc @justinsb @erictune @rata @miguelfrde

This is step two. We now create long-lived, lazy ECR providers in all regions.
When first used, they will create the actual ECR providers doing the work
behind the scenes, namely talking to ECR in the region where the image lives,
rather than the one our instance is running in.

Also:
- moved the list of AWS regions out of the AWS cloudprovider and into the
credentialprovider, then exported it from there.
- improved logging

Behold, running in us-east-1:

```
aws_credentials.go:127] Creating ecrProvider for us-west-2
aws_credentials.go:63] AWS request: ecr:GetAuthorizationToken in us-west-2
aws_credentials.go:217] Adding credentials for user AWS in us-west-2
Successfully pulled image "123456789012.dkr.ecr.us-west-2.amazonaws.com/test:latest"
```

*"One small step for a pod, one giant leap for Kube-kind."*

<!-- Reviewable:start -->
---
This change is [<img src="http://reviewable.k8s.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](http://reviewable.k8s.io/reviews/kubernetes/kubernetes/24369)
<!-- Reviewable:end -->
2016-05-13 15:15:45 -07:00
k8s-merge-robot 4ac4e0f6a2 Merge pull request #23495 from Clarifai/elb
Automatic merge from submit-queue

AWS: SSL support for ELB listeners through annotations

In the API, ports have only either TCP or UDP as their protocols, but ELB distinguishes HTTPS->HTTP[S]? from SSL->(SSL|TCP). 

Per #24978, this is implemented through two separate annotations:

`service.beta.kubernetes.io/aws-load-balancer-ssl-cert=arn:aws:acm:us-east-1:123456789012:certificate/12345678-1234-1234-1234-123456789012`
`service.beta.kubernetes.io/aws-load-balancer-backend-protocol=(https|http|ssl|tcp)`

Mixing plain-text and encrypted listeners will be in a separate PR, implementing #24978's `aws-load-balancer-ssl-ports=LIST`
2016-05-12 07:12:35 -07:00
David Oppenheimer 4ae37df7b7 Remove myself from a bunch of OWNERS files, as I am too overloaded
to do so many code reviews right now.
2016-05-11 13:34:51 -07:00
k8s-merge-robot e1fa044dba Merge pull request #24703 from hpcloud/hpe/vsphere-instance
Automatic merge from submit-queue

vSphere Cloud Provider Implementation 

This is the first PR towards implementation for vSphere cloud provider support in Kubernetes (ref. issue #23932).
2016-05-11 04:32:16 -07:00
Rudi Chiarito 6e6ea46182 Include changes from feedback
Use constructor for ecrProvider
Rename package to "credentials" like golint requests
Don't wrap the lazy provider with a caching provider
Add immedita compile-time interface conformance checks for the interfaces
Added comments
2016-05-10 12:03:40 -04:00
Rudi Chiarito eea29e8851 Allow cross-region image pulling with AWS' ECR
This is step two. We now create long-lived, lazy ECR providers in all regions.
When first used, they will create the actual ECR providers doing the work
behind the scenes, namely talking to ECR in the region where the image lives,
rather than the one our instance is running in.

Also:

- moved the list of AWS regions out of the AWS cloudprovider and into the
credentialprovider, then exported it from there.
- improved logging

Behold, running in us-east-1:

```
aws_credentials.go:127] Creating ecrProvider for us-west-2
aws_credentials.go:63] AWS request: ecr:GetAuthorizationToken in us-west-2
aws_credentials.go:217] Adding credentials for user AWS in us-west-2
Successfully pulled image 123456789012.dkr.ecr.us-west-2.amazonaws.com/test:latest"
```

*"One small step for a pod, one giant leap for Kube-kind."*
2016-05-10 12:03:39 -04:00
Rudi Chiarito 59334408a6 Change default when no BE proto given, add test for that
Also improve error message when BE proto is wrong
2016-05-10 11:53:44 -04:00
Rudi Chiarito e19c069b9d Add comment, rename getListener to buildListener 2016-05-10 11:40:34 -04:00
Zach Loafman faf0c44429 GCE: Allow nodes to exceed target pool maximums
If we would exceeded the TargetPool API maximums, instead just
randomly select some subsection of the nodes to include in the TP
instead.
2016-05-09 21:44:58 -07:00
dagnello f7b3cf39d6 Adding OWNERS file for vSphere cloud-provider package
also updating license file for Govmomi library
2016-05-09 08:55:42 -07:00
dagnello 4fd02f54ef Retreive VM Name from Running Instance
When vSphere cloud provider object is instantiated, the VM name of the
Node where this object is being create in needs to be set.  This patch
also includes vSphere as part of the cloud provider package.
2016-05-09 08:31:18 -07:00
dagnello c999cbaf8d VSphere Instance NodeAddresses ExternalID and InstanceID
This patch includes implementation for the following Instance object
interfaces:
* NodeAddresses
* ExternalID
* InstanceID

Also minor refactoring in overall Instance implementation.
2016-05-09 08:31:18 -07:00
Abitha Palaniappan 0d7d7fba60 Adding vSphere cloud provider support for Instance List 2016-05-09 08:31:18 -07:00
dagnello 88f6a6d66b Adding Zones Support for vSphere Cloud Provider 2016-05-09 08:31:18 -07:00
dagnello 051aa190e9 Adding vSphere Instances Scaffolding 2016-05-09 08:31:18 -07:00
Abitha Palaniappan c2045e8ee0 Add vSphere cloud provider skeleton 2016-05-09 08:31:18 -07:00
Alex Robinson 3d435b56be Merge pull request #25225 from a-robinson/fix
Actually populate nodeTags field in GCE provider struct
2016-05-05 14:35:01 -07:00
Alex Robinson 15874cd717 Actually populate nodeTags field in GCE provider struct 2016-05-05 21:26:54 +00:00
Alex Robinson b75fa08aec GCE: Prefer preconfigured node tags for firewalls, if available 2016-05-04 22:49:06 +00:00
Rudi Chiarito 898df1f52b Fix API fields to use new int32 sizes 2016-05-02 19:20:50 -04:00
Rudi Chiarito 61471965d8 Split annotation in two 2016-05-02 19:18:02 -04:00
Rudi Chiarito 7b7dd7861f Add support for HTTPS->HTTP ELB listeners through annotations
Moved listener creation to a separate function, which had the nice
side effect of allowing tests (added eight cases).
2016-05-02 19:18:01 -04:00
k8s-merge-robot 928990730e Merge pull request #24457 from leokhoa/master
Automatic merge from submit-queue

AWS: Add support for ap-northeast-2 region (Seoul)

This PR does:
- Support AWS Seoul region: ap-northeast-2. 
Currently, I can not setup Kubernetes on AWS Seoul.  
Error Messages: 

> 
> ip-10-0-0-50 core # docker logs 0697db
> I0419 07:57:44.569174       1 aws.go:466] Zone not specified in configuration file; querying AWS metadata service
> F0419 07:57:44.570380       1 controllermanager.go:279] Cloud provider could not be initialized: could not init cloud provider "aws": not a valid AWS zone (unknown region): ap-northeast-2a
2016-05-02 09:46:47 -07:00
Clayton Coleman fdb110c859
Fix the rest of the code 2016-04-29 17:12:10 -04:00
zhouhaibing089 bf1a3f99c0 Uncomment the code that cause by #19254 2016-04-25 23:21:31 +08:00
k8s-merge-robot 06160b6abe Merge pull request #22023 from mkulke/rackspace-improvements
Automatic merge from submit-queue

Rackspace improvements (OpenStack Cinder)

This adds PV support via Cinder on Rackspace clusters. Rackspace Cloud Block Storage is pretty much vanilla OpenStack Cinder, so there is no need for a separate Volume Plugin. Instead I refactored the Cinder/OpenStack interaction a bit (by introducing a CinderProvider Interface and moving the device path detection logic to the OpenStack part).

Right now this is limited to `AttachDisk` and `DetachDisk`. Creation and deletion of Block Storage is not in scope of this PR.

Also the `ExternalID` and `InstanceID` cloud provider methods have been implemented for Rackspace.
2016-04-21 16:38:13 -07:00
kulke ba4d74f3c7 Added Block Storage support to Rackspace provider, improved Node discovery. 2016-04-21 10:31:37 +02:00
goltermann 3fa6c6f6d9 Enable vet 2016-04-20 09:48:24 -07:00
Alex Robinson 23a8401c32 Merge pull request #24452 from a-robinson/dpv
Fix gce.getDiskByNameUnknownZone logic.
2016-04-19 11:58:04 -07:00
k8s-merge-robot db28f73c3b Merge pull request #24282 from goltermann/spelling
Automatic merge from submit-queue

Fix misspellings in comments
2016-04-19 03:47:07 -07:00
Khoa Le ce771effc6 Added AWS Seoul region 2016-04-19 15:20:39 +07:00
Alex Robinson d69ccd5c8c Fix gce.getDiskByNameUnknownZone logic. 2016-04-18 22:55:59 -07:00
k8s-merge-robot 1087162548 Merge pull request #23841 from dagnello/update-openstack-cloudprovider-volume-tests
Automatic merge from submit-queue

Extend OpenStack Cloud Provider Volume Tests

Adding coverage for:
getVolume
AttachDisk
DetachDisk
2016-04-16 17:44:09 -07:00
goltermann c226c9435b Fix misspellings in comments.
https://goreportcard.com/report/k8s.io/kubernetes#misspell
2016-04-14 13:57:45 -07:00
k8s-merge-robot 62d65f3ce6 Merge pull request #23770 from dagnello/update-openstack-cloudprovider-instance-tests
Automatic merge from submit-queue

Extend OpenStack Cloud Provider Instance Tests

Adding OpenStack cloud provider Instance coverage for:
ExternalID
InstanceID
2016-04-14 04:26:42 -07:00
Jeff Lowdermilk 9be85fbaf0 Merge pull request #23541 from bprashanth/fw_default
Default firewall port to TCP when unspecified.
2016-04-08 09:32:00 -07:00
dagnello cd7e99af1c Add OpenStack Cloud Provider Instance Tests
Adding OpenStack cloud provider instance unit tests for externalID and
instanceID.
2016-04-04 17:06:17 -07:00
dagnello 28590781c1 Extend OpenStack Cloud Provider Volume Tests
Adding test coverage for:
getVolume
AttachDisk
DetachDisk
2016-04-04 17:01:42 -07:00
zhouhaibing089 4758f9953b fix the gcfg typo 2016-03-29 23:32:11 +08:00
k8s-merge-robot 0c06f31cb8 Merge pull request #23340 from justinsb/fix_23339
Auto commit by PR queue bot
2016-03-29 05:04:27 -07:00
Prashanth Balasubramanian 7436fc6261 Default firewall port to TCP when unspecified. 2016-03-28 11:06:19 -07:00
k8s-merge-robot e44ad7a083 Merge pull request #22735 from resouer/throttle-dev
Auto commit by PR queue bot
2016-03-26 06:44:48 -07:00
k8s-merge-robot 4e4ad61260 Merge pull request #23366 from goltermann/vet
Auto commit by PR queue bot
2016-03-24 21:50:56 -07:00
harry 8472cfa214 Refactor throttle into util pkg
Fix missing throttle.go
2016-03-25 08:32:23 +08:00
Jan Safranek e4dc6709de Remove limit of attached AWS devices from kubelet.
Limit of nr. of attached EBS volumes to a node is now enforced by scheduler. It
can be adjusted by KUBE_MAX_PD_VOLS env. variable there.

Therefore we don't need the same check in kubelet. If the system admin wants to
attach more, we should allow it.

Kubelet limit is now 650 attached volumes ('ba'..'zz').
2016-03-23 12:07:16 +01:00
Chris Batey and James Ravn be9ce30897 Change LoadBalancer methods to take api.Service
This is a better abstraction than passing in specific pieces of the
Service that each of the cloudproviders may or may not need. For
instance, many of the providers don't need a region, yet this is passed
in. Similarly many of the providers want a string IP for the load
balancer, but it passes in a converted net ip. Affinity is unused by
AWS. A provider change may also require adding a new parameter which has
an effect on all other cloud provider implementations.

Further, this will simplify adding provider specific load balancer
options, such as with labels or some other metadata. For example, we
could add labels for configuring the details of an AWS elastic load
balancer, such as idle timeout on connections, whether it is
internal or external, cross-zone load balancing, and so on.

Authors: @chbatey, @jsravn
2016-03-23 10:48:11 +00:00
goltermann 34d4eaea08 Fixing several (but not all) go vet errors. Most are around string formatting, or unreachable code. 2016-03-22 17:26:50 -07:00
Justin Santa Barbara 59013f5507 AWS: Fix problems with >2 security groups
The previous logic was incorrect; if we saw two untagged security groups
before seeing the first tagged security, we would incorrectly return an
error.

Fix #23339
2016-03-22 13:00:14 -04:00