Strapi deployment with AWS application load balacer/ALB issue

System Information
  • 4.3.3:
  • ubuntu 20:
  • postgresql 12:
  • 16,17,18:
  • 8.15.0:
  • Yarn Version:

I have strapi running in EC2 and with elastic IP and it is public, say a.b.c.d


  • admin panel is : a.b.c.d:1337/admin.
  • My ALB, I had a target group map to port 1337.
  • From ALB, I made a rule for https(port 443) based on path for forward, say path rule is ‘/cms/*’ redirecting to my target group on ec2 instance on port 1337.
  • My ALB’s domain say
  • Now I would like to access, and i got the following,
{"data":null,"error":{"status":404,"name":"NotFoundError","message":"Not Found","details":{}}}

I tried the following in the server.js,

module.exports = ({ env }) => ({
host: env(‘HOST’, ‘’),
port:‘PORT’, 1337),
app: {
keys: env.array(‘APP_KEYS’),
url: ‘’

I have tried putting,

  • url: ‘’
  • url: ‘’
  • url: ‘’

None of these worked. I need a bit hint here, thanks!

I don’t believe this forum is the right place to ask anything any more.
It seems dead to me. Discord is the place where everyone is at the moment, albeit it is a super messy place and tough luck if you want to search for some past discussions…

@Kevin_Lee not that I know the answer. But when you put the “url:” into the server.js, did you rebuild the strapi? Basically, this config (and URL for the dashboard in particular) is used when the “yarn build”/ “npm build” is executed.

It gets baked into the webpack bundle and changing it will require re-building the bundle again.
So if you know your dashboard will have to be accessible as “” then set the url to this value and then do yarn build.

I hope this is the reason you are getting 404 at the moment and by following this suggestion you get it sorted…

@aveprik , thanks for the response. I believe i did ‘npm run build’ because we developed some plugins and we realize that webpack isn’t changed so the new things aren’t there. I can give another try. I will try out discord later. are all the devs so overwhelmed at this moment? I did not mind contributing to this open source thing but what is the strategies here. Aim for commercial?

Sorry, old topic but I am a slow poke :smiley:
I don’t work for Strapi so can’t answer your questions regards the contributions etc.

are all the devs so overwhelmed at this moment?

This seems to be the modus operandi for Strapi Devs :smiley:

I’m running into the same issue! Did you ever find a solution?