Skip to content
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

Update Web service configuration #4921

Closed
wkloucek opened this issue Oct 27, 2022 · 4 comments · Fixed by #6188
Closed

Update Web service configuration #4921

wkloucek opened this issue Oct 27, 2022 · 4 comments · Fixed by #6188
Assignees
Labels
Category:Enhancement Add new functionality Platform:Web Priority:p2-high Escalation, on top of current planning, release blocker

Comments

@wkloucek
Copy link
Contributor

Is your feature request related to a problem? Please describe.

Update the Web configuration in the oCIS Web service so that it reflects the current Web configuration.

Describe the solution you'd like

Have it all here:

// WebConfig defines the available web configuration for a dynamically rendered config.json.
type WebConfig struct {
Server string `json:"server,omitempty" yaml:"server" env:"OCIS_URL;WEB_UI_CONFIG_SERVER" desc:"URL, where the oCIS APIs are reachable for ownCloud Web."`
Theme string `json:"theme,omitempty" yaml:"-"`
OpenIDConnect OIDC `json:"openIdConnect,omitempty" yaml:"oidc"`
Apps []string `json:"apps" yaml:"apps"`
Applications []Application `json:"applications,omitempty" yaml:"applications"`
ExternalApps []ExternalApp `json:"external_apps,omitempty" yaml:"external_apps"`
Options map[string]interface{} `json:"options,omitempty" yaml:"options"`
}
// OIDC defines the available oidc configuration
type OIDC struct {
MetadataURL string `json:"metadata_url,omitempty" yaml:"metadata_url" env:"WEB_OIDC_METADATA_URL" desc:"URL for the OIDC well-known configuration endpoint. Defaults to the oCIS API URL + \"/.well-known/openid-configuration\"."`
Authority string `json:"authority,omitempty" yaml:"authority" env:"OCIS_URL;OCIS_OIDC_ISSUER;WEB_OIDC_AUTHORITY" desc:"URL of the OIDC issuer. It defaults to URL of the builtin IDP."`
ClientID string `json:"client_id,omitempty" yaml:"client_id" env:"WEB_OIDC_CLIENT_ID" desc:"OIDC client ID, which ownCloud Web uses. This client needs to be set up in your IDP."`
ResponseType string `json:"response_type,omitempty" yaml:"response_type" env:"WEB_OIDC_RESPONSE_TYPE" desc:"OIDC response type to use for authentication."`
Scope string `json:"scope,omitempty" yaml:"scope" env:"WEB_OIDC_SCOPE" desc:"OIDC scopes to request during authentication."`
}
// Application defines an application for the Web app switcher.
type Application struct {
Icon string `json:"icon,omitempty" yaml:"icon"`
Target string `json:"target,omitempty" yaml:"target"`
Title map[string]string `json:"title,omitempty" yaml:"title"`
Menu string `json:"menu,omitempty" yaml:"menu"`
URL string `json:"url,omitempty" yaml:"url"`
}
// ExternalApp defines an external web app.
// {
// "name": "hello",
// "path": "http://localhost:9105/hello.js",
// "config": {
// "url": "http://localhost:9105"
// }
// }
type ExternalApp struct {
ID string `json:"id,omitempty" yaml:"id"`
Path string `json:"path,omitempty" yaml:"path"`
// Config is completely dynamic, because it depends on the extension
Config map[string]interface{} `json:"config,omitempty" yaml:"config"`
}
// ExternalAppConfig defines an external web app configuration.
type ExternalAppConfig struct {
URL string `json:"url,omitempty" yaml:"url" env:""`
}
// Web defines the available web configuration.
type Web struct {
Path string `yaml:"path" env:"WEB_UI_PATH" desc:"Read the ownCloud Web configuration from this file path."`
ThemeServer string `yaml:"theme_server" env:"OCIS_URL;WEB_UI_THEME_SERVER" desc:"URL to load themes from. Will be prepended to the theme path."` // used to build Theme in WebConfig
ThemePath string `yaml:"theme_path" env:"WEB_UI_THEME_PATH" desc:"URL path to load themes from. The theme server will be prepended."` // used to build Theme in WebConfig
Config WebConfig `yaml:"config"`
}

cc @kulmann

@stale
Copy link

stale bot commented Dec 26, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 10 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the Status:Stale label Dec 26, 2022
@micbar micbar added the Category:Enhancement Add new functionality label Dec 28, 2022
@stale stale bot removed the Status:Stale label Dec 28, 2022
@micbar micbar added the Priority:p2-high Escalation, on top of current planning, release blocker label Apr 27, 2023
@micbar micbar moved this from Prio 2 to Prio 1 in Infinite Scale Team Board Apr 27, 2023
@micbar micbar moved this from Prio 1 to Prio 2 in Infinite Scale Team Board Apr 27, 2023
@kulmann
Copy link
Contributor

kulmann commented Apr 27, 2023

I don't understand the proposed solution. Do you mean that the options should be root level attributes in the WebConfig struct?

@micbar
Copy link
Contributor

micbar commented Apr 27, 2023

I don't understand the proposed solution. Do you mean that the options should be root level attributes in the WebConfig struct?

We should have a config struct representing the available options and defaults.

@micbar
Copy link
Contributor

micbar commented Apr 28, 2023

Available options: https://owncloud.dev/clients/web/getting-started/#options

Missing: logoutUrl

@kobergj kobergj self-assigned this Apr 28, 2023
@github-project-automation github-project-automation bot moved this from Prio 2 to Done in Infinite Scale Team Board May 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category:Enhancement Add new functionality Platform:Web Priority:p2-high Escalation, on top of current planning, release blocker
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

4 participants