config

package
v0.0.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	LintersSettings LintersSettings `mapstructure:"linters-settings"`
	WarningsOnly    []string        `mapstructure:"warnings-only"`
	// contains filtered or unexported fields
}

Config encapsulates the config data specified in the YAML config file.

func NewDefault

func NewDefault(dirs []string) (*Config, error)

type ContainerSettings

type ContainerSettings struct {
	SkipContainers []string `mapstructure:"skip-containers"`
}

type HelmSettings

type HelmSettings struct {
	SkipModuleImageName      []string `mapstructure:"skip-module-image-name"`
	SkipDistrolessImageCheck []string `mapstructure:"skip-distroless-image-check"`
	SkipHelmIgnoreCheck      []string `mapstructure:"skip-helm-ignore-check"`
	SkipNamespaceCheck       []string `mapstructure:"skip-namespace-check"`
}

type K8SResourcesSettings

type K8SResourcesSettings struct {
	SkipKubeRbacProxyChecks []string `mapstructure:"skip-kube-rbac-proxy-checks"`
	SkipContainerChecks     []string `mapstructure:"skip-container-checks"`
	SkipVPAChecks           []string `mapstructure:"skip-vpa-checks"`
	SkipPDBChecks           []string `mapstructure:"skip-pdb-checks"`
}

type LicenseSettings

type LicenseSettings struct {
	CopyrightExcludes []string `mapstructure:"copyright-excludes"`
	SkipOssChecks     []string `mapstructure:"skip-oss-checks"`
}

type LintersSettings

type LintersSettings struct {
	OpenAPI      OpenAPISettings      `mapstructure:"openapi"`
	NoCyrillic   NoCyrillicSettings   `mapstructure:"nocyrillic"`
	License      LicenseSettings      `mapstructure:"license"`
	Probes       ProbesSettings       `mapstructure:"probes"`
	Container    ContainerSettings    `mapstructure:"container"`
	K8SResources K8SResourcesSettings `mapstructure:"k8s_resources"`
	Helm         HelmSettings         `mapstructure:"helm"`
	Rbac         RbacSettings         `mapstructure:"rbac"`
	Resources    ResourcesSettings    `mapstructure:"resources"`
	Monitoring   MonitoringSettings   `mapstructure:"monitoring"`
}

type Loader

type Loader struct {
	// contains filtered or unexported fields
}

func NewLoader

func NewLoader(cfg *Config, dirs []string) *Loader

func (*Loader) Load

func (l *Loader) Load() error

type LoaderOptions

type LoaderOptions struct {
	Config string
}

type MonitoringSettings

type MonitoringSettings struct {
	SkipModuleChecks []string `mapstructure:"skip-module-checks"`
}

type NoCyrillicSettings

type NoCyrillicSettings struct {
	NoCyrillicFileExcludes []string `mapstructure:"no-cyrillic-file-excludes"`
	FileExtensions         []string `mapstructure:"file-extensions"`
	SkipDocRe              string   `mapstructure:"skip-doc-re"`
	SkipI18NRe             string   `mapstructure:"skip-i18n-re"`
	SkipSelfRe             string   `mapstructure:"skip-self-re"`
}

type OpenAPISettings

type OpenAPISettings struct {
	// EnumFileExcludes contains map with key string contained module name and file path separated by :
	EnumFileExcludes       map[string][]string `mapstructure:"enum-file-excludes"`
	HAAbsoluteKeysExcludes map[string]string   `mapstructure:"ha-absolute-keys-excludes"`
	KeyBannedNames         []string            `mapstructure:"key-banned-names"`
}

type ProbesSettings

type ProbesSettings struct {
	ProbesExcludes map[string][]string `mapstructure:"probes-excludes"`
}

type RbacSettings

type RbacSettings struct {
	SkipCheckWildcards     map[string][]string `mapstructure:"skip-check-wildcards"`
	SkipModuleCheckBinding []string            `mapstructure:"skip-module-check-binding"`
	SkipObjectCheckBinding []string            `mapstructure:"skip-object-check-binding"`
}

type ResourcesSettings

type ResourcesSettings struct{}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL