Custom Nginx config not being included?

0

I have a directory structure like so, and I want that Nginx partial to be included, but it looks like Nginx by default looks in /etc/nginx/conf.d, which

.platform/

  • hooks
  • nginx
    -- conf.d
    --- 01_proxy.conf

Is it a naming convention thing? The docs aren't super clear. I'm just setting the locations to forward traffic to my React front-end server and Node back-end. I was able to do it manually but I'd rather it be fool-proof against restarting/redeploying.

gefragt vor 3 Jahren1020 Aufrufe
2 Antworten
0

The highest rated answer looks like a likely solution for AL2: https://stackoverflow.com/questions/61333676/how-to-extend-nginx-config-in-elastic-beanstalk-amazon-linux-2

Basically, for location blocks use this: .platform/nginx/conf.d/elasticbeanstalk/location.conf

EDIT: Yup, that did the trick, and since 00_application.conf is generated by elastic beanstalk and has its own default / location block, I decided to remove that with a predeploy hook.

Edited by: DoodlyDev on Dec 30, 2020 6:59 PM

beantwortet vor 3 Jahren
0

Thanks to all for looking!

beantwortet vor 3 Jahren

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