config

package
v0.0.0-...-79b970a Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	DefaultConfigFilePath = "./.idpctl/config.yaml"
)

Variables

This section is empty.

Functions

func Enabled

func Enabled(component util.Components, client string) bool

func ParseFromFile

func ParseFromFile(cfg Config, filePath string) error

Types

type Config

type Config interface {
	// SetEnvVars registers environment variables from configuration file.
	SetEnvVars()
}

type GlobalConfig

type GlobalConfig struct {
	Namespace     string               `yaml:"namespace,omitempty"`
	StorageClass  string               `yaml:"storageClass,omitempty"`
	Git           *GlobalConfigGit     `yaml:"git,omitempty"`
	Ingress       *GlobalConfigIngress `yaml:"ingress,omitempty"`
	AdminPassword string               `yaml:"adminPassword,omitempty"`
	Harbor        *GlobalConfigHarbor  `yaml:"harbor,omitempty"`
	UI            *GlobalConfigUI      `yaml:"ui,omitempty"`
	Storage       *GlobalConfigStorage `yaml:"storage,omitempty"`
	Port          int                  `yaml:"port,omitempty"`
}

type GlobalConfigGit

type GlobalConfigGit struct {
	Username string                `yaml:"username,omitempty"`
	Token    string                `yaml:"token,omitempty"`
	Repo     string                `yaml:"repository,omitempty"`
	Email    string                `yaml:"email,omitempty"`
	Oauth    *GlobalConfigGitOauth `yaml:"oauth,omitempty"`
}

type GlobalConfigGitOauth

type GlobalConfigGitOauth struct {
	ClientID     string `yaml:"clientId,omitempty"`
	ClientSecret string `yaml:"clientSecret,omitempty"`
}

type GlobalConfigHarbor

type GlobalConfigHarbor struct {
	Host string `yaml:"host,omitempty"`
	TLS  bool   `yaml:"tls,omitempty"`
	Port int    `yaml:"port,omitempty"`
}

type GlobalConfigIngress

type GlobalConfigIngress struct {
	Host string `yaml:"host,omitempty"`
	TLS  bool   `yaml:"tls,omitempty"`
	Port int    `yaml:"port,omitempty"`
}

type GlobalConfigStorage

type GlobalConfigStorage struct {
	Username string `yaml:"username,omitempty"`
	Password string `yaml:"password,omitempty"`
	Database string `yaml:"database,omitempty"`
}

type GlobalConfigUI

type GlobalConfigUI struct {
	Host string `yaml:"host,omitempty"`
	Port int    `yaml:"port,omitempty"`
	TLS  bool   `yaml:"tls,omitempty"`
}

type StorageConfig

type StorageConfig struct {
	Type     string `yaml:"type,omitempty"`
	Host     string `yaml:"host,omitempty"`
	Username string `yaml:"username,omitempty"`
	Password string `yaml:"password,omitempty"`
	Database string `yaml:"database,omitempty"`
	Port     int    `yaml:"port,omitempty"`
}

Jump to

Keyboard shortcuts

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