Skip to content

Commit

Permalink
Auto merge of #2063 - jtgeibel:fastboot/fix-nginx-erb, r=jtgeibel
Browse files Browse the repository at this point in the history
Fix fastboot check in nginx erb template

In production we're currently returning a 502 Bad Gateway for
`/policies`.  I intend to merge this and deploy to production shortly.

This bug was introduced in #1907.  The bad check always evaluated to
true.  An explicit check for an empty string is added as well.  I've
tested this locally with `erb` and different values and the generated
configuration is now working correctly.

r? @jtgeibel
  • Loading branch information
bors committed Dec 25, 2019
2 parents a6c5f0d + f6b8b59 commit 55ed127
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion config/nginx.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ http {
location / {
proxy_pass http://localhost:9000;
}
<% elsif ['USE_FASTBOOT'] %>
<% elsif ENV['USE_FASTBOOT'] && !ENV['USE_FASTBOOT'].empty? %>
# Fastboot is enabled only for allowed paths

location = /policies {
Expand Down

0 comments on commit 55ed127

Please sign in to comment.