Merge pull request #45 from Bnyro/imageProxyUrl

include image proxy url and whether registration is disabled
This commit is contained in:
Bnyro 2023-08-14 10:36:22 +02:00 committed by GitHub
commit bacc784f59
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 27 additions and 21 deletions

View File

@ -38,10 +38,14 @@ type Instance struct {
LastChecked int64 `json:"last_checked"`
Cache bool `json:"cache"`
S3Enabled bool `json:"s3_enabled"`
ImageProxyUrl string `json:"image_proxy_url"`
RegistrationDisabled bool `json:"registration_disabled"`
}
type FrontendConfig struct {
S3Enabled bool `json:"s3Enabled"`
ImageProxyUrl string `json:"imageProxy"`
RegistrationDisabled bool `json:"registrationDisabled"`
}
var client = http.Client{
@ -192,6 +196,8 @@ func getInstanceDetails(split []string, latest string) (Instance, error) {
UpToDate: strings.Contains(latest, hash),
Cache: cacheWorking,
S3Enabled: config.S3Enabled,
ImageProxyUrl: config.ImageProxyUrl,
RegistrationDisabled: config.RegistrationDisabled,
}, nil
}