Commit Graph

16 Commits

Author SHA1 Message Date
Christian Joun e91ed11449
Implement API load balancer class with NLB and ELB support on AWS (#9011)
* refactor TargetLoadBalancer to use DNSTarget interface instead of LoadBalancer

* add LoadBalancerClass fields into api

* make api machinery

* WIP: Implemented API loadbalancer class, allowing NLB and ELB support on AWS for new clusters.

* perform vendoring related tasks and apply fixes identified from hack/

dissallow spotinst + nlb
remove reflection in status_discovery.go
Add precreated additional security groups to the Master nodes in case of NLB
Remove support for attaching individual instances to NLB; only rely on ASG attachments
Don't specify Classic loadbalancer in GCE integration test

* add utility function to the kops model context to make LoadBalancer comparisons simpler

* use DNSTarget interface when locating DNSName of API ELB

* wip: create target group task

* Consolidate TargetGroup tasks

* Use context helper for determining api load balancer type to avoid nil pointers

* Update NLB creation to use target group ARN from separate task rather than creating a TG in-line

* Address staticcheck and bazel failures

* Removing NLB Attachment tasks because they're not used since we switched to defining them as a part of the ASGs

* Address PR review feedback

* Only set LB Class field for AWS clusters, fix nil pointer

* Move target group attributes from NLB task to TG task, removing unused attributes

* Add terraform and cloudformation support for NLBs, listeners, and target groups

* Update integration test for NLB support

* Fix NLB name format to pass terraform validation

* Preserve security group rule names when switching ELB to NLB to reduce destructive terraform changes

* Use elbv2 enums and address some TODOs

* Set healthcheck values in target group

* Find TG tags, fix NLB name detection

* Fix more spurious changes reported by lifecycle integration test

* Fix spotinst validation, more code cleanup

* Address more PR feedback

* ReconcileTargetGroups unit test + more code simplification

* Addressing PR feedback Renaming task 1. awstasks.LoadBalancer -> awstasks.ClassicLoadBalancer

* Addressing PR feedback Renaming task: ELBName() -> CLBName() / LinkToELB() -> LinkToCLB()

* Addressing PR feedback: Various text changes

* fix export of kubecfg

* address TargetGroup should have the same name as the NLB

* should address error when fetching tags due to missing ARN

* Update expected and crds

* Add feature table to NLB docs

* Address more feedback and remove some TODOs that arent applicable anymore

* Update spotinst validation error message

Co-authored-by: Peter Rifel <pgrifel@gmail.com>
2020-11-02 05:28:52 -08:00
tanjunchen 977f987d65 fix-pkg-staticcheck and remove the repeat code 2019-12-03 10:32:37 +08:00
mikesplain 9e55b8230a Update copyright notices
Also cleans some white spaces
2019-09-09 14:47:51 -04:00
Alex Williams 834a63973d
Use EnsureTask for internal api route53 record 2019-03-16 17:43:31 +00:00
Rob Graham cc589ae538 Reworked to use loadbalancer only if config is specified 2018-07-02 12:02:50 +01:00
chrislovecnm 1e418c3e13 more goimport updates 2017-11-04 10:03:02 -06:00
Justin Santa Barbara 3dfe48e5ae Wiring up lifecycle 2017-07-15 22:03:54 -04:00
Justin Santa Barbara 9d40b0e6ca Support internal (gossip) names for AWS also 2017-06-19 14:16:35 -04:00
Justin Santa Barbara 864a999602 Fix automatic private DNS zone creation
We have to defer creation of the IAM policy until we have created the
hosted zone.

Fix #2444
2017-04-29 17:01:18 -04:00
Justin Santa Barbara 271367ba0f Don't add DNSZone task twice 2017-01-09 09:32:52 -05:00
Kris Nova 09f77d6753 Fixing hosted zone errors with bastion, and cleaning up dns model logic 2017-01-08 15:11:08 -05:00
Justin Santa Barbara e3b444c912 Fix double initialization of DNSZone
And, while we are it, clean up DNSZone so that it has separate notions
of TaskName, DNSName and HostedZoneID.  We conflated the three
previously, which we don't want to do at the task layer.  We don't want
to conflate the TaskName and the DNSName so that we can create a private
& public hosted zone with the same DNSName.  We don't want to "smuggle"
the hosted zone ID in the DNSName because it doesn't belong in the task
layer.

Fix #1374
2017-01-07 00:07:19 -05:00
Kris Nova 336237e879 Bug fixes and bastion reworking 2017-01-05 07:45:52 -07:00
Justin Santa Barbara ef14a1d172 Private DNS initial implementation - via feature flag 2016-12-26 14:03:31 -05:00
Justin Santa Barbara 50296f1a30 Fix file headers 2016-12-19 00:23:20 -05:00
Justin Santa Barbara fed68310fa Schema v1alpha2
* Zones are now subnets
* Utility subnet is no longer part of Zone
* Bastion InstanceGroup type added instead
* Etcd clusters defined in terms of InstanceGroups, not zones
* AdminAccess split into SSHAccess & APIAccess
* Dropped unused Multizone flag
2016-12-18 21:56:57 -05:00