-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Introducing ENV instead of flags for operator's main.go
skeleton manifest
#2388
Comments
I don't mind writing a PR if this is an acceptable feature. |
I think you are overstating it that env vars are a best practice. 12factor was an important step in the ops journey for many but it is neither dogma nor overall applicable in a modern setting. I think the more important "best practice" is consistency with all other Kubernetes daemons which use CLI flags rather than env vars. That said, if wanted to introduce Viper to the default skeleton to support both transparently, maybe that would be nice? |
+1 for the @coderanger POV and suggestion. Your help is more than welcome. |
@camilamacedo86, the reason I'm asking is to know if there's an acceptance to the concept since it's a major chunk ;-) Viper looks good. I haven't known this one :) |
Isn’t https://book.kubebuilder.io/component-config-tutorial/tutorial.html |
It really depends on how much it complicates things. As Jeesmon mentioned, there's potentially some motion towards in-band config via custom objects though that also hasn't gained much traction. |
label this as support and add to next milestone |
Hey, I see that the |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
@camilamacedo86 should we add it to go/v4 or also for go/v3? |
/remove-lifecycle rotten |
/assign @AlmogBaku |
note: make sure viper can handle one dash arguments as go flags (to support backward compatibility) |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close not-planned |
@k8s-triage-robot: Closing this issue, marking it as "Not Planned". In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
What do you want to happen?
Configuring operators with Environment Variables instead of
flags
is considered as best practice, especially due to the limitation to provide dynamic configurations over the flags (i.e. Secrets, ConfigMaps, etc.)Using flags can allow easier extensibility of the scaffold
main.go
, and compatibility with the 12factor manifest.In addition, I highly recommend the usage of
caarl0s/env
repository for simplicity orExtra Labels
No response
The text was updated successfully, but these errors were encountered: