I have 2 AWS EC2 instances sitting behind an Application Load Balancer. On each instance I have multiple multi-tenant Laravel apps deployed (app1.com, app2.com). As they are multi-tenant they'll have wildcard subdomains (demo.app1.com, demo.app2.com etc...)
Laravel Forge has a 000-catch-all nginx file in the sites-available/ folder which returns a status code of 444.
I'm trying to figure out what path I need to set for the target groups in AWS that will return a healthy 200 response. No matter what path I set for the health check, it always resolves to the 000-catch-all file and returns a 444 resulting in an 'unhealthy' instance.
Things I have tried:
Created a route (/health) in one of the apps that simply returns a 200 status code and set the health check path to both
/healthanddemo.app1.com/healthCreated a server block in both the
000-catch-alland theapp1.comfiles with a server block like,location /health { return 200 'OK'; }
The only thing that works is if I make the 000-catch-all file return a 200 instead of a 444 but that seems hacky.
Any ideas or something I might be missing?