From 27b7337e4c902cc42ebc350ad56e6fd997d6461d Mon Sep 17 00:00:00 2001 From: Paul Neubauer Date: Mon, 19 Jun 2023 10:50:00 +0200 Subject: [PATCH 1/5] feat: add logged out url config --- changelog/unreleased/enhancement-add-logged-out-url-config | 3 +++ services/web/pkg/config/options.go | 1 + 2 files changed, 4 insertions(+) create mode 100644 changelog/unreleased/enhancement-add-logged-out-url-config diff --git a/changelog/unreleased/enhancement-add-logged-out-url-config b/changelog/unreleased/enhancement-add-logged-out-url-config new file mode 100644 index 0000000000..e7e906cc23 --- /dev/null +++ b/changelog/unreleased/enhancement-add-logged-out-url-config @@ -0,0 +1,3 @@ +Enhancement: Add logged out url config + +Introduce a config to set the more button url on the access denied page in web via `WEB_OPTION_LOGGED_OUT_HELP`. diff --git a/services/web/pkg/config/options.go b/services/web/pkg/config/options.go index 0e8635ca5d..bb9bb48192 100644 --- a/services/web/pkg/config/options.go +++ b/services/web/pkg/config/options.go @@ -22,6 +22,7 @@ type Options struct { OpenLinksWithDefaultApp bool `json:"openLinksWithDefaultApp,omitempty" yaml:"openLinksWithDefaultApp" env:"WEB_OPTION_OPEN_LINKS_WITH_DEFAULT_APP" desc:"Specifies whether single file link shares should be opened with the default app or not. If not opened by the default app, the Web UI just displays the file details. Defaults to 'true'."` ImprintURL string `json:"imprintUrl,omitempty" yaml:"imprintUrl" env:"WEB_OPTION_IMPRINT_URL" desc:"Specifies the target url for the imprint link in the account menu"` PrivacyURL string `json:"privacyUrl,omitempty" yaml:"privacyUrl" env:"WEB_OPTION_PRIVACY_URL" desc:"Specifies the target url for the privacy link in the account menu"` + LoggedOutHelpURL string `json:"loggedOutHelpUrl,omitempty" yaml:"loggedOutHelpUrl" env:"WEB_OPTION_LOGGED_OUT_HELP" desc:"Specifies the target url for the generic logged out / access denied page"` } // AccountEditLink are the AccountEditLink options From afd8ef0d6804d2f0362a535c093e1c2f759685be Mon Sep 17 00:00:00 2001 From: Paul Neubauer Date: Mon, 19 Jun 2023 10:50:44 +0200 Subject: [PATCH 2/5] Add PR to changelog --- changelog/unreleased/enhancement-add-logged-out-url-config | 2 ++ 1 file changed, 2 insertions(+) diff --git a/changelog/unreleased/enhancement-add-logged-out-url-config b/changelog/unreleased/enhancement-add-logged-out-url-config index e7e906cc23..4021ae3a96 100644 --- a/changelog/unreleased/enhancement-add-logged-out-url-config +++ b/changelog/unreleased/enhancement-add-logged-out-url-config @@ -1,3 +1,5 @@ Enhancement: Add logged out url config Introduce a config to set the more button url on the access denied page in web via `WEB_OPTION_LOGGED_OUT_HELP`. + +https://github.com/owncloud/ocis/pull/6549 From b5d74f2f4cb201bdf01a7bc1ce0a9d03eda2d91a Mon Sep 17 00:00:00 2001 From: Paul Neubauer Date: Mon, 19 Jun 2023 12:35:26 +0200 Subject: [PATCH 3/5] Address PR issues --- services/web/pkg/config/options.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/services/web/pkg/config/options.go b/services/web/pkg/config/options.go index bb9bb48192..c86b7f6e80 100644 --- a/services/web/pkg/config/options.go +++ b/services/web/pkg/config/options.go @@ -20,9 +20,9 @@ type Options struct { ContextHelpersReadMore bool `json:"contextHelpersReadMore,omitempty" yaml:"contextHelpersReadMore" env:"WEB_OPTION_CONTEXTHELPERS_READ_MORE" desc:"Specifies whether the 'Read more' link should be displayed or not."` LogoutURL string `json:"logoutUrl,omitempty" yaml:"logoutUrl" env:"WEB_OPTION_LOGOUT_URL" desc:"Adds a link to the user's profile page to point him to an external page, where he can manage his session and devices. This is helpful when an external IdP is used. This option is disabled by default."` OpenLinksWithDefaultApp bool `json:"openLinksWithDefaultApp,omitempty" yaml:"openLinksWithDefaultApp" env:"WEB_OPTION_OPEN_LINKS_WITH_DEFAULT_APP" desc:"Specifies whether single file link shares should be opened with the default app or not. If not opened by the default app, the Web UI just displays the file details. Defaults to 'true'."` - ImprintURL string `json:"imprintUrl,omitempty" yaml:"imprintUrl" env:"WEB_OPTION_IMPRINT_URL" desc:"Specifies the target url for the imprint link in the account menu"` - PrivacyURL string `json:"privacyUrl,omitempty" yaml:"privacyUrl" env:"WEB_OPTION_PRIVACY_URL" desc:"Specifies the target url for the privacy link in the account menu"` - LoggedOutHelpURL string `json:"loggedOutHelpUrl,omitempty" yaml:"loggedOutHelpUrl" env:"WEB_OPTION_LOGGED_OUT_HELP" desc:"Specifies the target url for the generic logged out / access denied page"` + ImprintURL string `json:"imprintUrl,omitempty" yaml:"imprintUrl" env:"WEB_OPTION_IMPRINT_URL" desc:"Specifies the target URL for the imprint link in the account menu".` + PrivacyURL string `json:"privacyUrl,omitempty" yaml:"privacyUrl" env:"WEB_OPTION_PRIVACY_URL" desc:"Specifies the target URL for the privacy link in the account menu".` + AccessDeniedHelpURL string `json:"accessDeniedHelpURL,omitempty" yaml:"accessDeniedHelpURL" env:"WEB_OPTION_ACCESS_DENIED_HELP_URL" desc:"Specifies the target URL for the generic logged out / access denied page".` } // AccountEditLink are the AccountEditLink options From ca21a1448fe291c54f958491793c81f19c95d565 Mon Sep 17 00:00:00 2001 From: Paul Neubauer Date: Mon, 19 Jun 2023 12:38:15 +0200 Subject: [PATCH 4/5] Update changelog --- changelog/unreleased/enhancement-add-logged-out-url-config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog/unreleased/enhancement-add-logged-out-url-config b/changelog/unreleased/enhancement-add-logged-out-url-config index 4021ae3a96..01cf4d8161 100644 --- a/changelog/unreleased/enhancement-add-logged-out-url-config +++ b/changelog/unreleased/enhancement-add-logged-out-url-config @@ -1,5 +1,5 @@ Enhancement: Add logged out url config -Introduce a config to set the more button url on the access denied page in web via `WEB_OPTION_LOGGED_OUT_HELP`. +Introduce a config to set the more button url on the access denied page in web via `WEB_OPTION_ACCESS_DENIED_HELP_URL`. https://github.com/owncloud/ocis/pull/6549 From 47e366dd77773778e6025573770f9ea63d604161 Mon Sep 17 00:00:00 2001 From: Paul Neubauer Date: Mon, 19 Jun 2023 13:39:41 +0200 Subject: [PATCH 5/5] Address PR issue --- services/web/pkg/config/options.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/services/web/pkg/config/options.go b/services/web/pkg/config/options.go index c86b7f6e80..bd94400907 100644 --- a/services/web/pkg/config/options.go +++ b/services/web/pkg/config/options.go @@ -20,9 +20,9 @@ type Options struct { ContextHelpersReadMore bool `json:"contextHelpersReadMore,omitempty" yaml:"contextHelpersReadMore" env:"WEB_OPTION_CONTEXTHELPERS_READ_MORE" desc:"Specifies whether the 'Read more' link should be displayed or not."` LogoutURL string `json:"logoutUrl,omitempty" yaml:"logoutUrl" env:"WEB_OPTION_LOGOUT_URL" desc:"Adds a link to the user's profile page to point him to an external page, where he can manage his session and devices. This is helpful when an external IdP is used. This option is disabled by default."` OpenLinksWithDefaultApp bool `json:"openLinksWithDefaultApp,omitempty" yaml:"openLinksWithDefaultApp" env:"WEB_OPTION_OPEN_LINKS_WITH_DEFAULT_APP" desc:"Specifies whether single file link shares should be opened with the default app or not. If not opened by the default app, the Web UI just displays the file details. Defaults to 'true'."` - ImprintURL string `json:"imprintUrl,omitempty" yaml:"imprintUrl" env:"WEB_OPTION_IMPRINT_URL" desc:"Specifies the target URL for the imprint link in the account menu".` - PrivacyURL string `json:"privacyUrl,omitempty" yaml:"privacyUrl" env:"WEB_OPTION_PRIVACY_URL" desc:"Specifies the target URL for the privacy link in the account menu".` - AccessDeniedHelpURL string `json:"accessDeniedHelpURL,omitempty" yaml:"accessDeniedHelpURL" env:"WEB_OPTION_ACCESS_DENIED_HELP_URL" desc:"Specifies the target URL for the generic logged out / access denied page".` + ImprintURL string `json:"imprintUrl,omitempty" yaml:"imprintUrl" env:"WEB_OPTION_IMPRINT_URL" desc:"Specifies the target URL for the imprint link valid for the ocis instance in the account menu."` + PrivacyURL string `json:"privacyUrl,omitempty" yaml:"privacyUrl" env:"WEB_OPTION_PRIVACY_URL" desc:"Specifies the target URL for the privacy link valid for the ocis instance in the account menu."` + AccessDeniedHelpURL string `json:"accessDeniedHelpURL,omitempty" yaml:"accessDeniedHelpURL" env:"WEB_OPTION_ACCESS_DENIED_HELP_URL" desc:"Specifies the target URL valid for the ocis instance for the generic logged out / access denied page."` } // AccountEditLink are the AccountEditLink options