Cloudwatch SDK using putLogEvents() works locally but 504 Gateway timeout on my server (EC2)

0

I have a function that uses putLogEvents() method and it works fine locally but not when we push it out to our server (EC2 instance). We are always getting 504. I checked our LB and its allowing all traffic. I am running out of ideas why it is timing out on our server.

  • Also, when I do aws logs put-log-events ... on my EC2 server, it never responds back and I think that's why I'm getting 504 on my API but I'm not sure how to debug or see why its causing that to not respond.

  • I noticed that I can't telnet logs.us-west-2.amazonaws.com 443 on my EC2 instance

1 Antwort
0

If it is a timeout, check whether your EC2 has outbound internet access. And after that if the EC2 has sufficient permissions, then it will work.

beantwortet vor 2 Jahren
  • I can curl within that EC2 which means I have outbound internet access. What permission shall I be looking for on that EC2 instance?

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen