Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Create a KEDA deployment #398

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

matheusmazzoni
Copy link

What does this PR do?

This PR introduces the implementation of KEDA (Kubernetes Event-Driven Autoscaling) to the EKS Blueprints Addons repository. KEDA enables event-driven autoscaling for Kubernetes workloads, supporting a wide range of scalers like AWS SQS, CloudWatch, and DynamoDB. The integration is achieved by adding a simple configuration option to enable KEDA.

Motivation

The motivation behind this PR is to provide efficient resource utilization, enhance performance by dynamically adjusting workloads, and offer broad compatibility with various event sources.

More

  • Yes, I have tested the PR using my local account setup (Provide any test evidence report under Additional Notes)
  • Yes, I ran pre-commit run -a with this PR

For Moderators

  • E2E Test successfully complete before merge?

Additional Notes

In my local environment, KEDA successfully scaled applications based on event-driven triggers.

@matheusmazzoni matheusmazzoni requested a review from a team as a code owner May 25, 2024 03:05
@matheusmazzoni matheusmazzoni mentioned this pull request May 25, 2024
@matheusmazzoni matheusmazzoni changed the title feat: create a KEDA deployment Create a KEDA deployment May 25, 2024
@matheusmazzoni matheusmazzoni changed the title Create a KEDA deployment Feat: create a KEDA deployment May 25, 2024
@matheusmazzoni matheusmazzoni changed the title Feat: create a KEDA deployment feat: Create a KEDA deployment May 25, 2024
@matheusmazzoni
Copy link
Author

@bryantbiggs do you think this implementation is valid?

@bryantbiggs
Copy link
Contributor

no, I do not in its current form. As previously stated, this is just re-wrapping helm which is not providing much (if any) value. Users can deploy this today without any code changes required by the module #245 (comment)

What benefit is there to having just Terraform wrappers around Helm charts?

@vvchik
Copy link

vvchik commented Jun 13, 2024

It is logical to onboard it as It is a very popular hpa replacement. It is popular in the same way as Karpenter is a replacement for cluster-autoscaler.

@vvchik
Copy link

vvchik commented Jun 13, 2024

The main issue in that PR is it is not supporting irsa roles, like karpenter for example does.

so smth like that (maybe plain and not module) should be added

module "iam_assumable_role_keda" {
  source      = "terraform-aws-modules/iam/aws//modules/iam-assumable-role-with-oidc"
  create_role = true
  role_name   = "keda-role-${var.eks_cluster_name}"
  tags = {
    Role = "keda-role-${var.eks_cluster_name}"
  }
  # provider_url  = replace(var.eks_oidc_provider, "https://", "")
  provider_url = data.aws_eks_cluster.this.identity[0].oidc[0].issuer
  role_policy_arns = [
    "arn:aws:iam::aws:policy/CloudWatchReadOnlyAccess",
  ]
  oidc_fully_qualified_subjects = [
    "system:serviceaccount:keda:keda-operator",
  ]
}

and the following helm values should become configurable variables if irsa used

podIdentity:
  aws:
    irsa:
      enabled: true
      roleArn: "${keda_operator_role_arn}"    

serviceAccount:
  annotations:
    eks.amazonaws.com/role-arn: ${keda_operator_role_arn}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ADDON] - Keda
3 participants