Skip to content

[apigatewayv2] Simplify integration HTTP_PROXY with ALB ingressΒ #2580

@acharviakou

Description

@acharviakou

Is your feature request related to a problem?

As customer I would like to be able easily configure API gateway in front of EKS ingress(ALB ingress controller)
Currently it is possible using HTTP_PROXY apigw integration, but it is hard to get correct integrationURI
Currently we have workaround in pipeline to get such uri.

ingressHostname=$(kubectl get ingress ${ingressName} -n ${namespace} -o jsonpath='{.status.loadBalancer.ingress[0].hostname}')
loadBalancerARN=$(aws elbv2 describe-load-balancers --query LoadBalancers[?DNSName=='${ingressHostname}'].LoadBalancerArn  --output text)
aws elbv2 describe-listeners --load-balancer-arn ${loadBalancerARN} --query "Listeners[?Protocol=='HTTPS'].ListenerArn" --output text

This solution is not an ideal. For example there is race condition. You can not get integrationURI if you don't have ingress installed before.
It means to make new service fully working we have to run "helm apply" at least 2 times

Describe the solution you'd like
A description of what you want to happen.

Add some integration in controller to automatically detect integrationURI for ALB ingress
For example https://aws-controllers-k8s.github.io/community/reference/apigatewayv2/v1alpha1/integration/#spec
In current setup we can specify API gateway by ID, or by name of object.

apiID: string
apiRef: 
  from: 
    name: string
    namespace: string

It would be nice to have something similar here as well

Describe alternatives you've considered
A description of any alternative solutions or features you've considered.

Metadata

Metadata

Assignees

Labels

kroissues that can be resolved by kro

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions