-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow users to provide default values for unset environment variables #2313
Comments
Will look into this for Caddy 2, probably for all placeholder values spawning from the new Replacer type. |
Where can I follow the work on Caddy 2? Is there a list of features, breaking changes, estimated release date, etc somewhere? |
@aioobe It's not public yet, but when we get around to the public beta period, we'll move it into this repo! That's the plan as of now, anyway. Watch for announcements at OpenGo 2019. |
Related to / same as #1793 |
I'll close this as a duplicate of #1793 |
Actually, derp, they're not really the same. #1793 is for defaults for placeholders in general, whereas this is defaults for environment variables specifically. I'll reopen this but I'm also submitting a PR for this specific issue now 😛 |
Reading up on Environment Variables I don't see a way to specify default values for environment variables. This is a common feature in similar types of configuration files. Docker for example supports the standard bash syntax:
I would very much like to have a self contained
Caddyfile
with sane defaults so you can safely docaddy
in prod. (I don't want to say "oh, when you deploy in prod you need to follow instruction A, B and C", I would like it to be "Just runcaddy
".) And then something likeDOMAIN=staging caddy
/DOMAIN=dev caddy
to override relevant parts in staging and dev.The text was updated successfully, but these errors were encountered: