copilot-cli icon indicating copy to clipboard operation
copilot-cli copied to clipboard

Nlb healthcheck using http

Open CorinWilkins opened this issue 2 years ago • 1 comments

It's possible to configure the and nlb healthcheck to use http in the Aws console. I have a reverse proxy behind an nlb (deployed via copilot). On this proxy we have a healthcheck endpoint, however the nlb is declaring the service healthy before it is able to proxy requests. I believe it is because the nlb is able to establish a connection but the internals require more time before being able to proxy requests.

nlb:
    Healthcheck:
        Type:http
        Path:/healthcheck

CorinWilkins avatar Jan 21 '24 16:01 CorinWilkins

Hello, I have a couple points and a guess as to why the health check is falsely succeeding here. Because you don't have any target_container specified, it's possible that your nlb is sending traffic to the wrong container if you're expecting the traffic to go to a sidecar. Secondly, your manifest appears to be misconfigured. Copilot won't recognize the camel case formats as well as the type field doesn't exist, as copilot only uses http for health checks. A proper manifest might look like this:

nlb:
  target_container: [proxy container]
  healthcheck:
    path: '/healthcheck'

CaptainCarpensir avatar Jan 23 '24 17:01 CaptainCarpensir

This issue is stale because it has been open 60 days with no response activity. Remove the stale label, add a comment, or this will be closed in 14 days.

github-actions[bot] avatar Mar 25 '24 00:03 github-actions[bot]

This issue is closed due to inactivity. Feel free to reopen the issue if you have any further questions!

github-actions[bot] avatar Apr 09 '24 00:04 github-actions[bot]