-
-
Notifications
You must be signed in to change notification settings - Fork 208
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
Add webhome validator #2276
base: development
Are you sure you want to change the base?
Add webhome validator #2276
Conversation
… slashes both at the beginning and the end of the string Signed-off-by: DL6ER <[email protected]>
The check fails and the value is used. I tried with:
and the web interface is redirected to: |
The validator is not used when the env vars are used. But if you try to add an invalid
|
Yes, but that is because the validators cannot be used when using either the config file directly (or via env vars) because there is no way to communicate the warning/error to the user. What should we do in this case? Revert the config and overwrite what users have done? Ignore then env variable and use the default? It was unclear to me but rethinking this yesterday seems to make this a clear strategy. Note: This is a problem of general scope and not limited to the I think enforcing the validators on env vars (and falling back to ignoring the env var) is still somewhat doable as this will be in the container logs, I do find this more of an issue for direct config file changes. Your feelings may change, hence, I would like to talk about this. |
Yeah... I noticed that when I was checking the code. I agree with your PR suggestion, to validate env vars and send error messages to the log. Note: Not sure how to do it when the config file is directly edited. We can enforce the validation even in this case. If invalid, we set the value to default and send the errors to |
What does this implement/fix?
Add specific validator for
webserver.paths.webhome
ensuring there are slashes both at the beginning and the end of the stringRelated issue or feature (if applicable): Fixes #2274
Pull request in docs with documentation (if applicable): N/A
By submitting this pull request, I confirm the following:
git rebase
)Checklist:
developmental
branch.