This is a support request for Pulumi. I have a sta...
# general
i
This is a support request for Pulumi. I have a stack that deploys the helm chart 'aws-alb-ingress-controller', then creates an Ingress k8s resource. The combination of those two items results in the creation of an AWS ALB (the controller monitors Ingress resource CRUD and mirrors those changes in an ALB). The works perfectly when doing a 'pulumi up'. Here's the problem point. when doing a 'pulumi destroy', the controller is either destroyed before the Ingress deletion is noticed or the Ingress is deleted after the controller. How do I prevent this from happening? Is it possible to add a delay or hook or anything that will alter this processing? Thanks in advance.
b
You can specify `dependsOn' on the ingress resources https://www.pulumi.com/docs/intro/concepts/programming-model/#dependson
i
Thank you. I will give that a try.
Ok, that didn't do it. The dependency is being honored, but I'm guessing it's too fast and the controller isn't able to react to the Ingress deletion quickly enough.
Deleted resource kubernetesextensionsIngress • alb-istio-ingress 6 minutes ago Deleted resource kubernetes:rbac.authorization.k8s.io:ClusterRoleBinding • istio-system/aws-alb-ingress-controller 6 minutes ago Deleted resource kubernetescoreServiceAccount • istio-system/aws-alb-ingress-controller 6 minutes ago
Deleted resource kubernetes:rbac.authorization.k8s.io:ClusterRole • istio-system/aws-alb-ingress-controller 6 minutes ago Deleted resource kubernetesappsDeployment • istio-system/aws-alb-ingress-controller 6 minutes ago
b
do you need the ingress controller to pick-up the deletion of the ingress if the controller itself is being deleted a well?
oh right, the aws alb is weird AF,.
creates LB per ingress
We just moved away from the aws alb ingress controller to
nginx-ingress
for this reason. Creating all your routes inside one ingress resource was getting troublesome.
i
crap. unfortunately i don't have that option.
do you know of any delay options?
b
only thing I can think of is adding a sleep inside the
.apply
method of the ingress
but that would run the sleep every time your create it as well
i
ok, thx