1
0
mirror of https://github.com/siderolabs/kres.git synced 2026-02-05 09:45:35 +01:00
Files
kres/internal/project/auto/config.go
Utku Ozdemir dc032d7a4f fix: fix helm-docs and do various helm improvements
- Add valuesFiles option to HelmTemplate config for passing additional values files to helm template command
- Remove redundant -f values.yaml flag from helm template (chart's default values.yaml is used automatically)
- Remove --template-files flag with typo from helm-docs (default README.md.gotmpl is correct)
- Add buildx setup step to helm workflow to fix CI hang (was missing remote buildkit driver)
- Extract SetupBuildxStep() to avoid code duplication
- Add test helm chart to validate helm CI flow
- Fix the workdir of helm-docs

Signed-off-by: Utku Ozdemir <utku.ozdemir@siderolabs.com>
2026-01-30 12:14:44 +01:00

76 lines
2.2 KiB
Go

// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
package auto
// NamedConfig is a base type which provides config name.
type NamedConfig struct {
name string
}
// Name implements named interface.
func (cfg *NamedConfig) Name() string {
return cfg.name
}
// CommandConfig sets up settings for command build.
type CommandConfig struct {
NamedConfig
DisableImage bool `yaml:"disableImage"`
}
// CustomSteps defines custom steps to be generated.
type CustomSteps struct {
Steps []CustomStep `yaml:"steps"`
}
// CustomStep defines a custom step to be built.
type CustomStep struct {
Name string `yaml:"name"`
Inputs []string `yaml:"inputs"`
Dependants []string `yaml:"dependants"`
Toplevel bool `yaml:"toplevel"`
}
// CI defines CI settings.
type CI struct {
Provider string `yaml:"provider"`
// CompileGHWorkflowsOnly is a flag to generate only GitHub Actions.
CompileGHWorkflowsOnly bool `yaml:"compileGHWorkflowsOnly"`
}
// Helm defines helm settings.
type Helm struct {
ChartDir string `yaml:"chartDir"`
E2EDir string `yaml:"e2eDir"`
Template HelmTemplate `yaml:"template"`
Enabled bool `yaml:"enabled"`
DocsDisabled bool `yaml:"docsDisabled"`
}
// HelmTemplate defines helm template settings.
type HelmTemplate struct {
ValuesFiles []string `yaml:"valuesFiles"`
Set []string `yaml:"set"`
SetFile []string `yaml:"setFile"`
SetJSON []string `yaml:"setJSON"`
SetLiteral []string `yaml:"setLiteral"`
SetString []string `yaml:"setString"`
}
// IntegrationTests defines integration tests builder to be generated.
type IntegrationTests struct {
Tests []IntegrationTestConfig `yaml:"tests"`
}
// IntegrationTestConfig defines the integration tests build configuration.
type IntegrationTestConfig struct {
Outputs map[string]map[string]string `yaml:"outputs"`
Name string `yaml:"name"`
Path string `yaml:"path"`
ImageName string `yaml:"imageName"`
EnableDockerImage bool `yaml:"enableDockerImage"`
}