Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

NewToLaravel's avatar

Where do I add my normal nginx configuration?

Hi!

So this is my first time using a load-balancer and I've set it up nicely (thanks Forge!), but i'm confused as to where I place my normal nginx configuration, like redirecting non-www requests to www, or setting expire times for assets.

Do I change the load-balancer conf or the nginx conf on each individual server?

Sorry if it's a silly question!

Thank you

0 likes
2 replies
Tray2's avatar

On the individual server. The load balancer is only like a traffic cop deciding which road your request should take.

NewToLaravel's avatar

@TRAY2 - I thought so, I just wanted to make sure! Better safe that sorry lol I knew my question was silly!

Please or to participate in this conversation.