heroku / heroku-buildpack-static

[DEPRECATED] Heroku buildpack for handling static sites and single page web apps
MIT License
674 stars 427 forks source link

How can I inject a boolean HTTPS_ONLY env value into the respective JSON value? #224

Closed JaffParker closed 2 years ago

JaffParker commented 2 years ago

I need to have HTTPS enabled for my prod server, but disabled on staging. So I tried this:

"https_only": "${HTTPS_ONLY}",

But it doesn't seem to work, which makes sense, since it becomes "https_only": "false", which is a truthy value. So there seems to be no way to inject a boolean value into this.

Am I missing a solution?

JaffParker commented 2 years ago

So after some research it seems indeed impossible, since it just injects a string.

So this is more of a feature request now lol. Is it possible to add a parser to boolean fields?

edmorley commented 2 years ago

Hi

This buildpack is now deprecated and we are recommending people move the more actively maintained heroku-buildpack-nginx. For migration advice see here.

As such, I'm closing this issue out since we won't be making further changes to this buildpack.