From 86c5fb5fab7765a9c620cb5c205b29b37892ba15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Wei=C3=9Fe?= <66256922+daniel-weisse@users.noreply.github.com> Date: Wed, 2 Aug 2023 16:01:10 +0200 Subject: [PATCH] config: reorder values (#2154) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Daniel Weiße --- internal/config/config.go | 12 ++++++------ internal/config/config_doc.go | 24 ++++++++++++------------ 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/internal/config/config.go b/internal/config/config.go index 198fbf370..32c4e61d1 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -80,17 +80,17 @@ type Config struct { // DON'T USE IN PRODUCTION: enable debug mode and use debug images. DebugCluster *bool `yaml:"debugCluster" validate:"required"` // description: | - // Supported cloud providers and their specific configurations. - Provider ProviderConfig `yaml:"provider" validate:"dive"` - // description: | - // Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation - Attestation AttestationConfig `yaml:"attestation" validate:"dive"` - // description: | // Optional custom endpoint (DNS name) for the Constellation API server. // This can be used to point a custom dns name at the Constellation API server // and is added to the Subject Alternative Name (SAN) field of the TLS certificate used by the API server. // A fallback to DNS name is always available. CustomEndpoint string `yaml:"customEndpoint" validate:"omitempty,hostname_rfc1123"` + // description: | + // Supported cloud providers and their specific configurations. + Provider ProviderConfig `yaml:"provider" validate:"dive"` + // description: | + // Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation + Attestation AttestationConfig `yaml:"attestation" validate:"dive"` } // ProviderConfig are cloud-provider specific configuration values used by the CLI. diff --git a/internal/config/config_doc.go b/internal/config/config_doc.go index 79a9d8437..fb2ca64e9 100644 --- a/internal/config/config_doc.go +++ b/internal/config/config_doc.go @@ -70,21 +70,21 @@ func init() { ConfigDoc.Fields[6].Note = "" ConfigDoc.Fields[6].Description = "DON'T USE IN PRODUCTION: enable debug mode and use debug images." ConfigDoc.Fields[6].Comments[encoder.LineComment] = "DON'T USE IN PRODUCTION: enable debug mode and use debug images." - ConfigDoc.Fields[7].Name = "provider" - ConfigDoc.Fields[7].Type = "ProviderConfig" + ConfigDoc.Fields[7].Name = "customEndpoint" + ConfigDoc.Fields[7].Type = "string" ConfigDoc.Fields[7].Note = "" - ConfigDoc.Fields[7].Description = "Supported cloud providers and their specific configurations." - ConfigDoc.Fields[7].Comments[encoder.LineComment] = "Supported cloud providers and their specific configurations." - ConfigDoc.Fields[8].Name = "attestation" - ConfigDoc.Fields[8].Type = "AttestationConfig" + ConfigDoc.Fields[7].Description = "Optional custom endpoint (DNS name) for the Constellation API server.\nThis can be used to point a custom dns name at the Constellation API server\nand is added to the Subject Alternative Name (SAN) field of the TLS certificate used by the API server.\nA fallback to DNS name is always available." + ConfigDoc.Fields[7].Comments[encoder.LineComment] = "Optional custom endpoint (DNS name) for the Constellation API server." + ConfigDoc.Fields[8].Name = "provider" + ConfigDoc.Fields[8].Type = "ProviderConfig" ConfigDoc.Fields[8].Note = "" - ConfigDoc.Fields[8].Description = "Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation" - ConfigDoc.Fields[8].Comments[encoder.LineComment] = "Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation" - ConfigDoc.Fields[9].Name = "customEndpoint" - ConfigDoc.Fields[9].Type = "string" + ConfigDoc.Fields[8].Description = "Supported cloud providers and their specific configurations." + ConfigDoc.Fields[8].Comments[encoder.LineComment] = "Supported cloud providers and their specific configurations." + ConfigDoc.Fields[9].Name = "attestation" + ConfigDoc.Fields[9].Type = "AttestationConfig" ConfigDoc.Fields[9].Note = "" - ConfigDoc.Fields[9].Description = "Optional custom endpoint (DNS name) for the Constellation API server.\nThis can be used to point a custom dns name at the Constellation API server\nand is added to the Subject Alternative Name (SAN) field of the TLS certificate used by the API server.\nA fallback to DNS name is always available." - ConfigDoc.Fields[9].Comments[encoder.LineComment] = "Optional custom endpoint (DNS name) for the Constellation API server." + ConfigDoc.Fields[9].Description = "Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation" + ConfigDoc.Fields[9].Comments[encoder.LineComment] = "Configuration for attestation validation. This configuration provides sensible defaults for the Constellation version it was created for.\nSee the docs for an overview on attestation: https://docs.edgeless.systems/constellation/architecture/attestation" ProviderConfigDoc.Type = "ProviderConfig" ProviderConfigDoc.Comments[encoder.LineComment] = "ProviderConfig are cloud-provider specific configuration values used by the CLI."