From 763c9dfa6b79559cc78f44a9967f5a3b53a6bae9 Mon Sep 17 00:00:00 2001 From: Christoph Kluge Date: Tue, 3 Dec 2024 15:22:34 +0100 Subject: [PATCH 1/2] fix schema definition of apiAllowedIPs --- pkg/schema/schemas/config.schema.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkg/schema/schemas/config.schema.json b/pkg/schema/schemas/config.schema.json index e1b7dc8..c04dd74 100644 --- a/pkg/schema/schemas/config.schema.json +++ b/pkg/schema/schemas/config.schema.json @@ -10,7 +10,10 @@ }, "apiAllowedIPs": { "description": "Addresses from which secured API endpoints can be reached", - "type": "string" + "type": "array", + "items": { + "type": "string" + } }, "user": { "description": "Drop root permissions once .env was read and the port was taken. Only applicable if using privileged port.", From 4fecbe820d0e6491598df42156373e8935adeb3b Mon Sep 17 00:00:00 2001 From: Christoph Kluge Date: Tue, 3 Dec 2024 17:11:32 +0100 Subject: [PATCH 2/2] change order to match docs --- pkg/schema/config.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/schema/config.go b/pkg/schema/config.go index 0a30d86..f9116cf 100644 --- a/pkg/schema/config.go +++ b/pkg/schema/config.go @@ -164,13 +164,13 @@ type ProgramConfig struct { // Defines time X in seconds in which jobs are considered to be "short" and will be filtered in specific views. ShortRunningJobsDuration int `json:"short-running-jobs-duration"` - // Array of Clusters - Clusters []*ClusterConfig `json:"clusters"` - // Energy Mix CO2 Emission Constant [g/kWh] // If entered, displays estimated CO2 emission for job based on jobs totalEnergy EmissionConstant int `json:"emission-constant"` // Frequency of cron job workers CronFrequency *CronFrequency `json:"cron-frequency"` + + // Array of Clusters + Clusters []*ClusterConfig `json:"clusters"` }