kra-oa/app/system/internal/service/system_config.go

27 lines
666 B
Go

package service
import (
"context"
"encoding/json"
"kra/app/system/internal/dto"
)
func (s *SystemConfigService) PersistConfig(ctx context.Context) error {
return s.uc.PersistConfig(ctx)
}
func (s *SystemConfigService) ReloadConfig(ctx context.Context) error {
return s.uc.ReloadConfig(ctx)
}
func (s *SystemConfigService) DiskMountPoints() []string { return s.uc.DiskMountPoints() }
func (s *SystemConfigService) SystemConfig() (json.RawMessage, error) {
return s.uc.ConfigurationJSON()
}
func (s *SystemConfigService) SaveSystemConfig(ctx context.Context, req *dto.SetSystemConfigRequest) error {
return s.uc.SaveConfigurationJSON(ctx, req.Config)
}