config

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsToolSupported

func IsToolSupported(tool string) bool

IsToolSupported checks if a tool is supported

Types

type ConfigData

type ConfigData struct {
	// Map of additional tools enabled
	AdditionalTools map[string]bool
	// Command execution timeout in seconds
	Timeout int
	// Security configuration
	SecurityConfig *security.SecurityConfig

	// Command-line specific options
	Transport       string
	Host            string
	Port            int
	AccessLevel     string
	AllowNamespaces string
}

ConfigData holds the global configuration

func NewConfig

func NewConfig() *ConfigData

NewConfig creates and returns a new configuration instance

func (*ConfigData) ParseFlags

func (cfg *ConfigData) ParseFlags() error

ParseFlags parses command line arguments and updates the configuration

type Validator

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

Validator handles all validation logic for MCP Kubernetes

func NewValidator

func NewValidator(cfg *ConfigData) *Validator

NewValidator creates a new validator instance

func (*Validator) GetErrors

func (v *Validator) GetErrors() []string

GetErrors returns all errors found during validation

func (*Validator) PrintErrors

func (v *Validator) PrintErrors()

PrintErrors prints all validation errors to stdout

func (*Validator) Validate

func (v *Validator) Validate() bool

Validate runs all validation checks

Jump to

Keyboard shortcuts

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