-
Notifications
You must be signed in to change notification settings - Fork 9.7k
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
Doc: update etcd configuration detail with config file #9066
Conversation
Do we have a doc about the syntax and options for the config file? For
example how do we map command line flags to config file yaml fields?
…On Sun, Dec 24, 2017 at 11:56 AM Sahdev Zala ***@***.***> wrote:
/cc @gyuho <https://github.com/gyuho> @xiang90
<https://github.com/xiang90>
Since the config file itself is used through a command line flag, I didn't
create a new section but tried to add detail in the current sections on
configuration flags. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9066 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AERby5aMEvwaR0H3LfdB_Tu2rKeXQOgeks5tDqxlgaJpZM4RMAKL>
.
|
@xiang90 it seems like configuration.md is the doc which has all the flags usage and syntax documented that can be used in the config file. |
@xiang90 I have tried modifying a line to show the relationship/mapping between file and flags as "A reusable configuration file is a YAML file made of one or more command-line flags...." if that look good? Thanks! |
|
||
A reusable configuration file is a YAML file made of one or more command-line flags described below. In order to use this file, specify the file path as a value to the `--config-file` flag. The [sample configuration file][sample-config-file] can be used as a starting point to create a new configuration file as needed. | ||
|
||
Options set on the command line take precedence over those from the environment. If a configuration file is provided, other command line flags will be ignored. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If a configuration file is provided, will env also be ignored? or they will be overwritten?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we clarify that here too besides other command line flags will be ignored
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably we should also add some logging in etcd itself saying config file is provided, xxx are ignored.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to be in this PR though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree, both suggestions makes sense!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have created second commit with your suggestions related to ignoring flags. Thanks!
@@ -2,9 +2,10 @@ | |||
|
|||
etcd is configurable through a configuration file, various command-line flags, and environment variables. | |||
|
|||
A reusable configuration file is a YAML file made of one or more command-line flags described below. In order to use this file, specify the file path as a value to the `--config-file` flag. The [sample configuration file][sample-config-file] can be used as a starting point to create a new configuration file as needed. | |||
A reusable configuration file is a YAML file made with name and value of one or more command-line flags described below. In order to use this file, specify the file path as a value to the `--config-file` flag. The [sample configuration file][sample-config-file] can be used as a starting point to create a new configuration file as needed. | |||
|
|||
Options set on the command line take precedence over those from the environment. If a configuration file is provided, other command line flags will be ignored. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If a configuration file is provided, other command line flags will be ignored.
->
If a configuration file is provided, other command line flags and env variables will be ignored.
LGTM after add |
8e86d9a
to
253d1d4
Compare
Add a reference, sample file link and precedence detail etc. to the configuration doc.
@xiang90 sorry, squashing was messed up so I had to push few times to fix it but I hope it looks good now. Thanks! |
Thanks. Will merge when CI is green. Merry Christmas.
…On Sun, Dec 24, 2017 at 9:08 PM Sahdev Zala ***@***.***> wrote:
@xiang90 <https://github.com/xiang90> sorry, squashing was messaged up so
I had to push few times to fix it but I hope it looks good now. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9066 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AERby0oOTniIYcw7PwA13AN2Utu2PBBnks5tDwODgaJpZM4RMAKL>
.
|
@xiang90 thanks!! Merry Christmas. |
Adding information that when config file is used other command line flags and env variables will be ignored. This changes are a follow up of a disucssion under PR, etcd-io#9066
Add a reference of the config file, sample file link and precedence detail to the
configuration doc.
Fixes #9063
Contributing guidelines
Please read our contribution workflow before submitting a pull request.