sqsd 404 when posting messages to our app only on new Elastic Beanstalk instances

0

I have an elastic beanstalk worker environment running a NodeJS app on "Node.js 16 running on 64bit Amazon Linux 2/5.5.3". After a recent terraform deploy(which, as far as I can tell, only updated our instances to the latest version, 5.5.3), we noticed that no jobs were being processed in the worker env. When I looked at the logs I noticed lines like the following in nginx.log:

127.0.0.1 - - [23/Jun/2022:21:23:15 +0000] "POST /jobs HTTP/1.1" 404 3665 "-" "aws-sqsd/3.0.4" "-"

My app is not generating these 404s, nginx is. My app is running on port 8081, we have the PORT EV set to 8081 and this has normally allowed sqsd to post to nginx at port 80 and have it redirected to our node.js app on port 8081, but this seemingly has stopped working on new instances. If I reboot the instance all is well and it seems to create the 80->8081 rule or whatever the internal beanstalk processes are supposed to do and the nginx log shows "200" statuses and our jobs are processed.

Has anyone seen this before? We only recent updated to the NodeJS 16 platform, I believe we were using nodeJS 12 before, but when we initially deployed we had no issues with the app.

JMV8
asked 2 years ago321 views
1 Answer
0
Accepted Answer

After spending a bit of time debugging this I realized that the problem was that I was still configuring nginx using .ebextensions instead of .platform. I moved my configuration to .platform and all is well now.

JMV8
answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions