MCPcopy Index your code
hub / github.com/1Panel-dev/1Panel / GetAppstoreConfig

Method GetAppstoreConfig

core/app/service/setting.go:697–716  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

695}
696
697func (u *SettingService) GetAppstoreConfig() (*dto.AppstoreConfig, error) {
698 res := &dto.AppstoreConfig{}
699 res.UninstallDeleteImage, _ = settingRepo.GetValueByKey("UninstallDeleteImage")
700 if res.UninstallDeleteImage == "" {
701 res.UninstallDeleteImage = constant.StatusDisable
702 }
703 res.UpgradeBackup, _ = settingRepo.GetValueByKey("UpgradeBackup")
704 if res.UpgradeBackup == "" {
705 res.UpgradeBackup = constant.StatusDisable
706 }
707 res.UninstallDeleteBackup, _ = settingRepo.GetValueByKey("UninstallDeleteBackup")
708 if res.UninstallDeleteBackup == "" {
709 res.UninstallDeleteBackup = constant.StatusDisable
710 }
711 res.InstallAllowPort, _ = settingRepo.GetValueByKey("InstallAllowPort")
712 if res.InstallAllowPort == "" {
713 res.InstallAllowPort = constant.StatusDisable
714 }
715 return res, nil
716}
717
718func loadDockerProxy(req dto.ProxyUpdate) string {
719 if req.ProxyType == "" || req.ProxyType == "close" || !req.ProxyDocker {

Callers

nothing calls this directly

Calls 1

GetValueByKeyMethod · 0.65

Tested by

no test coverage detected