https://pulumi.com logo
#general
Title
# general
m

millions-furniture-75402

05/21/2020, 3:59 PM
I’m trying to setup default behavior for a load balancer listener, but I run into an issue with defaulActions. Can someone shed some light on what I might be doing wrong?
b

best-lifeguard-91445

05/21/2020, 4:08 PM
What is the default action you're trying to specify? When specifying the targetGroup, a
defaultAction
is created, and will forward requests to the provided targetGroup. Also, you can create a listener from the target group and specify the default action:
Copy code
appTargetGroup.createListener("appListerner", { 
   port: 80,
   protocol: "HTTPS",
   defaultAction: { ... }
});
m

millions-furniture-75402

05/21/2020, 4:10 PM
404 by default
b

best-lifeguard-91445

05/21/2020, 4:31 PM
Try specifying the default action as part of the listener initialization -- Your rule looks fine to me. I'll have to defer to others - I'm relatively new to pulumi 🙂
m

millions-furniture-75402

05/21/2020, 4:32 PM
Okay, I appreciate the effort. It could help me in my search. The other issue, is I’m trying to share 1 ALB between maybe apps, so I want a default targetGroup listener, I guess? Not sure.