-
Notifications
You must be signed in to change notification settings - Fork 187
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
Hardcoded web options #6188
Hardcoded web options #6188
Conversation
74ccc69
to
527d6db
Compare
💥 Acceptance test Web-Tests-ocis-smoke-ocis-storage-1 failed. Further test are cancelled... |
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.
LGTM from docs pov
07d808d
to
8a5dfdf
Compare
Signed-off-by: jkoberg <[email protected]>
Co-authored-by: Martin <[email protected]>
8a5dfdf
to
6cb5be4
Compare
seems that we have some fallout here from the options. @JammingBen Any ideas how that could break the selenium tests? |
Note that Is it desired for oCIS to return all those values now? If so, the default values have to be implemented in oCIS I suppose. |
@JammingBen Thanks for digging into it. We need to omit empty values to use the web defaults. |
} | ||
|
||
// XHR are the XHR options | ||
type XHR struct { | ||
Timeout int `json:"timeout" yaml:"timeout" desc:"Specifies the timeout for XHR uploads in milliseconds."` | ||
Timeout int `json:"timeout,omitempty" yaml:"timeout" env:"WEB_OPTION_UPLOAD_XHR_TIMEOUT" desc:"Specifies the timeout for XHR uploads in milliseconds."` |
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.
this one was missing
@JammingBen @kobergj @mmattel Ocis default is now {
"previewFileMimeTypes": [
"image/gif",
"image/png",
"image/jpeg",
"text/plain",
"image/tiff",
"image/bmp",
"image/x-ms-bmp"
],
"sharingRecipientsPerPage": 200,
"sidebar": {
"shares": {
"showAllOnLoad": false
}
},
"routing": {
"idBased": true
},
"contextHelpersReadMore": true
} @kulmann FYI |
Some empty defaults are omitted on the json object. They are relying on the web default. Please speak up if you think that we should make all of the defaults explicit. |
Kudos, SonarCloud Quality Gate passed! |
Consider before merging: Following point for ease of readbility/identification: For naming the envvars to identify its purpose we have set that they start with: If one is looking for all options that configure the webui, not the web service itself, he can clearly identify them in the envvars but not in the yamls. Proposal: This also would help documenting that there are options to configure the webui behaviour as I could then reference to a common name component in both the envvars table and the yaml table. |
@mmattel The yaml is nested: web:
options:
feedbacklink:
href: https://www.example.com |
I would prefer to define the defaults implicitly in web. I need to define them there anyway because:
|
To make admins aware about the implicit setting made by the webui, we could add what is implicit set in the envvar description. Else, how does an admin know what is configured? |
Mentioning the defaults from web in the env var descriptions is a good idea, yes. |
What is missing? I added some. |
The feedback link defaults are already mentioned. The rest is IMO part of the ocis defaults and thereby documented. Probably missing:
|
* use custom struct for web options Signed-off-by: jkoberg <[email protected]> * update envvar descriptions Co-authored-by: Martin <[email protected]> * Use correct defaults * fix code style --------- Signed-off-by: jkoberg <[email protected]> Co-authored-by: Michael Barz <[email protected]> Co-authored-by: Martin <[email protected]> Co-authored-by: Michael Barz <[email protected]>
Not relevant for oCIS as we use TUS there. |
* use custom struct for web options Signed-off-by: jkoberg <[email protected]> * update envvar descriptions Co-authored-by: Martin <[email protected]> * Use correct defaults * fix code style --------- Signed-off-by: jkoberg <[email protected]> Co-authored-by: Michael Barz <[email protected]> Co-authored-by: Martin <[email protected]> Co-authored-by: Michael Barz <[email protected]>
Fixes #4921