config

package
v0.0.0-...-03b3356 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WatchConfigChange

func WatchConfigChange() <-chan Config

Types

type AiOptions

type AiOptions struct {
	Namespace  string `json:"namespace" yaml:"namespace"`
	NamePrefix string `json:"namePrefix" yaml:"namePrefix"`
}

AiOptions defines all the needs from ai

type Config

type Config struct {
	KubernetesOptions *k8s.KubernetesOptions `json:"kubernetes,omitempty" yaml:"kubernetes,omitempty" mapstructure:"kubernetes"`
	AiOptions         *AiOptions             `json:"ai" yaml:"ai" mapstructure:"ai"`
	// 缓存配置,缓存token
	CacheOptions *cache.Options `json:"cache,omitempty" yaml:"cache,omitempty" mapstructure:"cache"`
	// 认证服务配置,开启关闭等
	AuthenticationOptions *authoptions.AuthenticationOptions `json:"authentication,omitempty" yaml:"authentication,omitempty" mapstructure:"authentication"`
}

Config defines everything needed for apiserver to deal with external services

func New

func New() *Config

func TryLoadFromDisk

func TryLoadFromDisk() (*Config, error)

Jump to

Keyboard shortcuts

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