Feature/audit certificate upload (#30223)
* feat: Add certificate upload option for audit logging settings * Commit current changes * Additions * MM-62944 Fix fileupload settings not being clickable * Support for uploading a cert for experimental audit logging cert. Pre cloud implementation in the backend * Forgot to add new hook * Add support for setting custom audit log certifcates in Cloud * Permissions * I18n * Change order * Linter fixes * Linter fixes, add openapi spec * additions for openapi * More openapi fixes because it won't run locally * Undo, cursor went rogue * newline fix * Align types properly * Fix i18n * Fix i18n AGAIN * Fix error * Update api/v4/source/audit_logging.yaml --------- Co-authored-by: Harrison Healey <harrisonmhealey@gmail.com> Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
@@ -1538,6 +1538,7 @@ type ExperimentalAuditSettings struct {
|
||||
FileCompress *bool `access:"experimental_features,write_restrictable,cloud_restrictable"`
|
||||
FileMaxQueueSize *int `access:"experimental_features,write_restrictable,cloud_restrictable"`
|
||||
AdvancedLoggingJSON json.RawMessage `access:"experimental_features"`
|
||||
Certificate *string `access:"experimental_features"` // telemetry: none
|
||||
}
|
||||
|
||||
func (s *ExperimentalAuditSettings) SetDefaults() {
|
||||
@@ -1572,6 +1573,10 @@ func (s *ExperimentalAuditSettings) SetDefaults() {
|
||||
if utils.IsEmptyJSON(s.AdvancedLoggingJSON) {
|
||||
s.AdvancedLoggingJSON = []byte("{}")
|
||||
}
|
||||
|
||||
if s.Certificate == nil {
|
||||
s.Certificate = NewPointer("")
|
||||
}
|
||||
}
|
||||
|
||||
// GetAdvancedLoggingConfig returns the advanced logging config as a []byte.
|
||||
|
||||
Ссылка в новой задаче
Block a user