Skip to content

Add EKS auto discovery for dynamic integration based fetchers.#38204

Merged
AntonAM merged 24 commits intomasterfrom
anton/eks-auto-enrollment
Feb 29, 2024
Merged

Add EKS auto discovery for dynamic integration based fetchers.#38204
AntonAM merged 24 commits intomasterfrom
anton/eks-auto-enrollment

Conversation

@AntonAM
Copy link
Copy Markdown
Contributor

@AntonAM AntonAM commented Feb 14, 2024

This PR adds dynamic kube watchers that use integration as means of authentication to AWS, it will be used for Discover UI EKS integration in auto-discovery mode.

@AntonAM AntonAM added kubernetes-access discovery no-changelog Indicates that a PR does not require a changelog entry backport/branch/v15 labels Feb 14, 2024
@AntonAM AntonAM force-pushed the anton/eks-auto-enrollment branch 3 times, most recently from f39b50e to 028d3dc Compare February 14, 2024 21:11
@AntonAM AntonAM marked this pull request as ready for review February 14, 2024 21:11
@github-actions github-actions Bot requested review from mdwn and rosstimothy February 14, 2024 21:12
@AntonAM AntonAM force-pushed the anton/eks-auto-enrollment branch from 028d3dc to ec18d97 Compare February 14, 2024 23:43
Comment thread api/types/kubernetes.go Outdated
Comment thread api/types/kubernetes_server.go Outdated
Comment thread lib/authz/permissions.go Outdated
Comment thread lib/srv/discovery/discovery.go Outdated
Comment thread lib/srv/discovery/discovery.go Outdated
Comment thread lib/authz/permissions.go Outdated
Comment thread lib/service/discovery.go Outdated
Comment thread lib/services/kubernetes.go Outdated
Comment thread lib/srv/discovery/kube_integration_watcher.go Outdated
Comment thread lib/srv/discovery/fetchers/eks.go Outdated
Comment thread lib/srv/discovery/fetchers/eks.go Outdated
Comment thread lib/auth/api.go Outdated
Comment thread lib/auth/api.go Outdated
Comment thread lib/auth/auth_with_roles.go Outdated
Comment thread lib/services/kubernetes.go Outdated
Comment thread lib/srv/discovery/fetchers/eks.go Outdated
Comment thread lib/srv/discovery/kube_integration_watcher.go Outdated
@AntonAM AntonAM force-pushed the anton/eks-auto-enrollment branch from 726f690 to 736bd91 Compare February 27, 2024 19:34
Comment thread lib/srv/discovery/discovery.go Outdated
@AntonAM AntonAM force-pushed the anton/eks-auto-enrollment branch from 736bd91 to fff35c4 Compare February 28, 2024 15:38
@AntonAM AntonAM changed the base branch from master to anton/awsoidc-grpc-enroll-eks-clusters February 28, 2024 15:38
Comment thread api/types/kubernetes.go Outdated
@AntonAM AntonAM force-pushed the anton/awsoidc-grpc-enroll-eks-clusters branch 4 times, most recently from c614736 to 9c3b91f Compare February 28, 2024 19:11
Base automatically changed from anton/awsoidc-grpc-enroll-eks-clusters to master February 28, 2024 19:46
@AntonAM AntonAM force-pushed the anton/eks-auto-enrollment branch from a682f97 to 960584e Compare February 28, 2024 20:35
Comment thread lib/srv/discovery/discovery.go Outdated
Comment thread lib/srv/discovery/kube_integration_watcher.go Outdated
Comment thread lib/srv/discovery/kube_integration_watcher.go
@public-teleport-github-review-bot public-teleport-github-review-bot Bot removed the request for review from mdwn February 28, 2024 23:03
@zmb3
Copy link
Copy Markdown
Collaborator

zmb3 commented Feb 29, 2024

/excludeflake *

@AntonAM AntonAM added this pull request to the merge queue Feb 29, 2024
Merged via the queue into master with commit 89d8565 Feb 29, 2024
@AntonAM AntonAM deleted the anton/eks-auto-enrollment branch February 29, 2024 00:29
@public-teleport-github-review-bot
Copy link
Copy Markdown

@AntonAM See the table below for backport results.

Branch Result
branch/v15 Failed

AntonAM added a commit that referenced this pull request Feb 29, 2024
* AWSOIDC: Move enrollment of EKS clusters to the gRPC service.

* Fix after rebase.

* Add EKS auto discovery for dynamic integration based fetchers.

* Remove commented code.

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

* Remove unneeded code.

Co-authored-by: Marco André Dinis <marco.dinis@goteleport.com>

* Add missing godoc.

* Initiate map with length.

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

* Fix typo in the interface name.

* Introduce iam join method for EKS enrollment.

* Correctly process DiscoveredEKSCluster in kube watcher.

* Remove remaining CreateToken related code from Discovery service.

* Change var initialization.

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

* Remove dev version detection for EKS enrollment.

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>

* Revert "Introduce iam join method for EKS enrollment."

This reverts commit 0eb3f4f1226239a5d4e768ebe9129535be318ccb.

* Fix usage of a missing function.

* Refactor cluster features to be a function.

* Change discovery to use gRPC call for EKS enrollment.

* Remove unused mock.

* Correct a comment.

* Remove token creation permission from Discovery service.

* Fix after rebase.

* Improve sorting clusters by region and integration.

Co-authored-by: Tiago Silva <tiago.silva@goteleport.com>

* Return and error if cluster features are missing.

* Fix tests.

---------

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>
Co-authored-by: Marco André Dinis <marco.dinis@goteleport.com>
Co-authored-by: Tiago Silva <tiago.silva@goteleport.com>
github-merge-queue Bot pushed a commit that referenced this pull request Feb 29, 2024
… (#38772)

* AWSOIDC: Move enrollment of EKS clusters to the gRPC service.

* Fix after rebase.

* Add EKS auto discovery for dynamic integration based fetchers.

* Remove commented code.



* Remove unneeded code.



* Add missing godoc.

* Initiate map with length.



* Fix typo in the interface name.

* Introduce iam join method for EKS enrollment.

* Correctly process DiscoveredEKSCluster in kube watcher.

* Remove remaining CreateToken related code from Discovery service.

* Change var initialization.



* Remove dev version detection for EKS enrollment.



* Revert "Introduce iam join method for EKS enrollment."

This reverts commit 0eb3f4f1226239a5d4e768ebe9129535be318ccb.

* Fix usage of a missing function.

* Refactor cluster features to be a function.

* Change discovery to use gRPC call for EKS enrollment.

* Remove unused mock.

* Correct a comment.

* Remove token creation permission from Discovery service.

* Fix after rebase.

* Improve sorting clusters by region and integration.



* Return and error if cluster features are missing.

* Fix tests.

---------

Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com>
Co-authored-by: Marco André Dinis <marco.dinis@goteleport.com>
Co-authored-by: Tiago Silva <tiago.silva@goteleport.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

discovery kubernetes-access no-changelog Indicates that a PR does not require a changelog entry size/lg

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants