Compare commits

...
1 Commits
Author SHA1 Message Date
Benedikt Kulmann a9ac0f9309 feat(frontend): add OX capabilities 2026-06-10 10:22:13 +02:00
3 changed files with 15 additions and 0 deletions

No files matched your search

+7
View File
@@ -63,6 +63,8 @@ type Config struct {
Groupware Groupware `yaml:"groupware"`
OpenXchange OpenXchange `yaml:"open_xchange"`
Context context.Context `yaml:"-"`
}
@@ -223,3 +225,8 @@ type PasswordPolicy struct {
type Groupware struct {
Enabled bool `yaml:"enabled" env:"FRONTEND_GROUPWARE_ENABLED" desc:"Enable groupware features. Defaults to false." introductionVersion:"3.7.0"`
}
type OpenXchange struct {
Enabled bool `yaml:"enabled" env:"FRONTEND_OPENXCHANGE_ENABLED" desc:"Enable Open-Xchange integration. Defaults to false." introductionVersion:"%%NEXT_PRODUCTION_VERSION%%"`
ApiUrl string `yaml:"api_url" env:"FRONTEND_OPENXCHANGE_API_URL" desc:"The URL of the Open-Xchange API. Required if Open-Xchange integration is enabled." introductionVersion:"%%NEXT_PRODUCTION_VERSION%%"`
}
@@ -158,6 +158,10 @@ func DefaultConfig() *config.Config {
Groupware: config.Groupware{
Enabled: false,
},
OpenXchange: config.OpenXchange{
Enabled: false,
ApiUrl: "",
},
}
}
@@ -343,6 +343,10 @@ func FrontendConfigFromStruct(cfg *config.Config, logger log.Logger) (map[string
"groupware": map[string]any{
"enabled": cfg.Groupware.Enabled,
},
"open_xchange": map[string]any{
"enabled": cfg.OpenXchange.Enabled,
"api_url": cfg.OpenXchange.ApiUrl,
},
},
"version": map[string]any{
"product": "OpenCloud",