{"modulePath":"github.com/maximilien/weave-cli","version":"v0.15.0","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package stack\n\n## Constants\n\n```go\nconst (\n\t// DefaultStackFile is the default name for stack configuration\n\tDefaultStackFile = \"weave-stack.yaml\"\n\n\t// DefaultStateDir is the directory for stack state\n\tDefaultStateDir = \".weave-state\"\n)\n```\n\n## Functions\n\n```go\nfunc CheckDependencies(runtime string) error\n```\nCheckDependencies verifies required tools are installed\n\n```go\nfunc CommandExists(cmd string) bool\n```\nCommandExists checks if a command is available in PATH\n\n```go\nfunc CopyHelmTemplates(outputDir string) error\n```\nCopyHelmTemplates copies Helm chart templates to output directory\n\n```go\nfunc DeleteCluster(info *ClusterInfo) error\n```\nDeleteCluster deletes the cluster based on provider\n\n```go\nfunc EnhanceClusterError(err error, provider string) error\n```\nEnhanceClusterError adds helpful context to cluster errors\n\n```go\nfunc EnhanceHelmError(err error, chartPath, releaseName string) error\n```\nEnhanceHelmError adds helpful context to Helm errors\n\n```go\nfunc EnhancePodError(err error, podName, context string) error\n```\nEnhancePodError adds helpful context to pod errors\n\n```go\nfunc FilterFilesFromCheckpoint(files []string, checkpoint *IngestCheckpoint, resumeFrom string) ([]string, int, error)\n```\nFilterFilesFromCheckpoint filters file list based on checkpoint state\n\n```go\nfunc GenerateHelmChart(config *StackConfig, outputDir string) error\n```\nGenerateHelmChart generates complete Helm chart from StackConfig\n\n```go\nfunc GeneratePM2Config(config *StackConfig, outputPath string) error\n```\nGeneratePM2Config generates ecosystem.config.js from template\n\n```go\nfunc GetClusterStatus(info *ClusterInfo) (string, error)\n```\nGetClusterStatus gets the current status of the cluster\n\n```go\nfunc GetPodLogs(selector, context string, follow bool, tail int) error\n```\nGetPodLogs streams logs from pods matching selector\n\n```go\nfunc GetRuntimeVersion(runtime ContainerRuntime) (string, error)\n```\nGetRuntimeVersion gets the version of a container runtime\n\n```go\nfunc HelmInstall(chartPath, releaseName, namespace string, timeout string, context string) error\n```\nHelmInstall installs a Helm chart\n\n```go\nfunc HelmUninstall(releaseName, namespace string, context string) error\n```\nHelmUninstall uninstalls a Helm release\n\n```go\nfunc IngestToStack(cfg IngestConfig) error\n```\nIngestToStack runs ingestion pipeline targeting stack Milvus\n\n```go\nfunc PM2List() (string, error)\n```\nPM2List lists all PM2 processes\n\n```go\nfunc PM2Logs(appName string, lines int, follow bool) error\n```\nPM2Logs streams logs from PM2\n\n```go\nfunc PM2Monit() error\n```\nPM2Monit opens PM2 monitoring interface\n\n```go\nfunc PM2Restart(appName string) error\n```\nPM2Restart restarts the PM2 process\n\n```go\nfunc PM2Start(appName, configPath string) error\n```\nPM2Start starts the dashboard with PM2\n\n```go\nfunc PM2Status(appName string) (string, error)\n```\nPM2Status returns the PM2 process status\n\n```go\nfunc PM2Stop(appName string) error\n```\nPM2Stop stops the PM2 process\n\n```go\nfunc SaveCheckpoint(checkpoint *IngestCheckpoint, path string) error\n```\nSaveCheckpoint saves a checkpoint to disk\n\n```go\nfunc SaveClusterInfo(info *ClusterInfo) error\n```\nSaveClusterInfo saves cluster information to state directory\n\n```go\nfunc SaveHelmValues(values *HelmValues, outputPath string) error\n```\nSaveHelmValues saves Helm values to a file\n\n```go\nfunc SaveStackConfig(config *StackConfig, path string) error\n```\nSaveStackConfig saves configuration to YAML file\n\n```go\nfunc StackExists() bool\n```\nStackExists checks if weave-stack.yaml exists in current directory\n\n```go\nfunc ValidateConfig(config *StackConfig) error\n```\nValidateConfig validates the stack configuration\n\n```go\nfunc ValidateRuntime(runtime ContainerRuntime) error\n```\nValidateRuntime ensures the specified runtime is available\n\n```go\nfunc WaitForPods(selector, context string, timeout time.Duration) error\n```\nWaitForPods waits for pods matching selector to be Ready\n\n## Types\n\n```go\ntype APIRoute struct {\n\tPath       string   `yaml:\"path\"`\n\tCollection string   `yaml:\"collection,omitempty\"`\n\tType       string   `yaml:\"type,omitempty\"` // \"search\", \"healthcheck\"\n\tMethods    []string `yaml:\"methods,omitempty\"`\n\tAuth       string   `yaml:\"auth,omitempty\"` // \"required\", \"optional\", \"none\"\n}\n```\nAPIRoute defines an API route\n\n```go\ntype AutoScaling struct {\n\tMinNodeCount int `yaml:\"min_node_count\"`\n\tMaxNodeCount int `yaml:\"max_node_count\"`\n}\n```\nAutoScaling defines auto-scaling configuration\n\n```go\ntype BackupConfig struct {\n\tEnabled       bool   `yaml:\"enabled\"`\n\tSchedule      string `yaml:\"schedule,omitempty\"`\n\tRetentionDays int    `yaml:\"retention_days,omitempty\"`\n}\n```\nBackupConfig defines backup configuration\n\n```go\ntype BuildConfig struct {\n\tDockerfile string `yaml:\"dockerfile,omitempty\"`\n\tContext    string `yaml:\"context,omitempty\"`\n\tTarget     string `yaml:\"target,omitempty\"`\n\tCache      bool   `yaml:\"cache,omitempty\"`\n}\n```\nBuildConfig defines build configuration\n\n```go\ntype CheckpointConfig struct {\n\tEnabled      bool   `yaml:\"enabled\"`\n\tPath         string `yaml:\"path,omitempty\"`\n\tSaveInterval int    `yaml:\"save_interval,omitempty\"`\n}\n```\nCheckpointConfig defines checkpointing\n\n```go\ntype ChunkingConfig struct {\n\tStrategy     string `yaml:\"strategy\"` // \"semantic\", \"fixed\", \"sentence\"\n\tChunkSize    int    `yaml:\"chunk_size\"`\n\tChunkOverlap int    `yaml:\"chunk_overlap,omitempty\"`\n}\n```\nChunkingConfig defines how to chunk documents\n\n```go\ntype CleanupConfig struct {\n\tRemoveCheckpointsOnSuccess bool `yaml:\"remove_checkpoints_on_success,omitempty\"`\n\tRetainLogsDays             int  `yaml:\"retain_logs_days,omitempty\"`\n\tCompressOldLogs            bool `yaml:\"compress_old_logs,omitempty\"`\n}\n```\nCleanupConfig defines cleanup policies\n\n```go\ntype ClusterInfo struct {\n\tName             string    `json:\"name\"`\n\tProvider         string    `json:\"provider\"` // \"kind\", \"minikube\", \"eks\", \"gke\"\n\tContext          string    `json:\"context\"`  // kubectl context name\n\tContainerRuntime string    `json:\"container_runtime\"`\n\tCreatedAt        time.Time `json:\"created_at\"`\n\tStatus           string    `json:\"status\"` // \"active\", \"stopped\", \"error\"\n}\n```\nClusterInfo stores information about the active cluster\n\n```go\nfunc CreateKindCluster(config *StackConfig) (*ClusterInfo, error)\n```\nCreateKindCluster creates a Kind cluster with the specified configuration\n\n```go\nfunc CreateMinikubeCluster(config *StackConfig) (*ClusterInfo, error)\n```\nCreateMinikubeCluster creates a Minikube cluster with the specified configuration\n\n```go\nfunc LoadClusterInfo() (*ClusterInfo, error)\n```\nLoadClusterInfo loads cluster information from state directory\n\n```go\ntype CollectionConfig struct {\n\tName        string           `yaml:\"name\"`\n\tType        string           `yaml:\"type\"` // \"text\", \"image\"\n\tDescription string           `yaml:\"description,omitempty\"`\n\tSchema      SchemaConfig     `yaml:\"schema\"`\n\tSources     []DataSource     `yaml:\"sources\"`\n\tChunking    *ChunkingConfig  `yaml:\"chunking,omitempty\"`\n\tEmbedding   *EmbeddingConfig `yaml:\"embedding,omitempty\"`\n}\n```\nCollectionConfig defines a data collection\n\n```go\ntype CollectionIngestConfig struct {\n\tSource        string   `yaml:\"source\"` // File path or glob pattern\n\tEmbedding     string   `yaml:\"embedding,omitempty\"`\n\tType          string   `yaml:\"type,omitempty\"` // \"text\" or \"image\"\n\tImages        bool     `yaml:\"images,omitempty\"`\n\tImageStorage  string   `yaml:\"image_storage,omitempty\"`\n\tMinioBucket   string   `yaml:\"minio_bucket,omitempty\"`\n\tChunkSize     int      `yaml:\"chunk_size,omitempty\"`\n\tWorkers       int      `yaml:\"workers,omitempty\"`\n\tBatchSize     int      `yaml:\"batch_size,omitempty\"`\n\tRestartEvery  int      `yaml:\"restart_every,omitempty\"`\n\tSkipAllImages bool     `yaml:\"skip_all_images,omitempty\"`\n\tFlags         []string `yaml:\"flags,omitempty\"` // Additional CLI flags\n}\n```\nCollectionIngestConfig defines ingestion for a specific collection\n\n```go\ntype ContainerRuntime string\n```\nContainerRuntime represents a container runtime\n\n```go\nconst (\n\tRuntimePodman ContainerRuntime = \"podman\"\n\tRuntimeDocker ContainerRuntime = \"docker\"\n\tRuntimeNone   ContainerRuntime = \"none\"\n)\n```\n\n```go\nfunc DetectContainerRuntime() (ContainerRuntime, error)\n```\nDetectContainerRuntime detects which container runtime is available Priority: podman \u003e docker (OSS-first preference)\n\n```go\nfunc GetRuntimeCommand(preferredRuntime string) (ContainerRuntime, error)\n```\nGetRuntimeCommand returns the appropriate runtime command based on detection\n\n```go\ntype DashboardConfig struct {\n\tEnabled bool          `yaml:\"enabled\"`\n\tType    string        `yaml:\"type\"`    // \"web\", \"cli\", \"none\"\n\tRuntime string        `yaml:\"runtime\"` // \"pm2\", \"kubernetes\", \"docker\", \"manual\"\n\tPM2     *PM2Config    `yaml:\"pm2,omitempty\"`\n\tWeb     *WebDashboard `yaml:\"web,omitempty\"`\n}\n```\nDashboardConfig defines dashboard configuration\n\n```go\ntype DashboardState struct {\n\tStatus string `json:\"status\"` // \"running\", \"stopped\", \"error\"\n\tURL    string `json:\"url,omitempty\"`\n\tPort   int    `json:\"port,omitempty\"`\n}\n```\nDashboardState stores dashboard status\n\n```go\ntype DataSource struct {\n\tPattern string                 `yaml:\"pattern\"`        // Glob pattern\n\tType    string                 `yaml:\"type\"`           // \"pdf\", \"docx\", \"txt\"\n\tMode    string                 `yaml:\"mode,omitempty\"` // \"text-only\", \"image-extraction\"\n\tOptions map[string]interface{} `yaml:\"options,omitempty\"`\n}\n```\nDataSource defines where data comes from\n\n```go\ntype DeploymentConfig struct {\n\tReplicas     int    `yaml:\"replicas\"`\n\tStorageClass string `yaml:\"storage_class\"`\n\tPVCSize      string `yaml:\"pvc_size\"`\n}\n```\nDeploymentConfig defines K8s Deployment settings\n\n```go\ntype DevConfig struct {\n\tHotReload bool   `yaml:\"hot_reload,omitempty\"`\n\tPort      int    `yaml:\"port,omitempty\"`\n\tCommand   string `yaml:\"command,omitempty\"`\n}\n```\nDevConfig defines development mode configuration\n\n```go\ntype EKSConfig struct {\n\tRegion     string         `yaml:\"region\"`\n\tNodeGroups []EKSNodeGroup `yaml:\"node_groups\"`\n}\n```\nEKSConfig is AWS EKS configuration\n\n```go\ntype EKSNodeGroup struct {\n\tName         string `yaml:\"name\"`\n\tInstanceType string `yaml:\"instance_type\"`\n\tDesiredSize  int    `yaml:\"desired_size\"`\n\tMinSize      int    `yaml:\"min_size\"`\n\tMaxSize      int    `yaml:\"max_size\"`\n}\n```\nEKSNodeGroup defines an EKS node group\n\n```go\ntype EmbeddingConfig struct {\n\tModel    string `yaml:\"model\"`\n\tProvider string `yaml:\"provider\"`\n}\n```\nEmbeddingConfig defines embedding model\n\n```go\ntype FailedFile struct {\n\tFile     string `json:\"file\"`\n\tError    string `json:\"error\"`\n\tAttempts int    `json:\"attempts\"`\n}\n```\nFailedFile represents a failed ingestion attempt\n\n```go\ntype GKEConfig struct {\n\tZone      string        `yaml:\"zone\"`\n\tNodePools []GKENodePool `yaml:\"node_pools\"`\n}\n```\nGKEConfig is GCP GKE configuration\n\n```go\ntype GKENodePool struct {\n\tName        string       `yaml:\"name\"`\n\tMachineType string       `yaml:\"machine_type\"`\n\tNodeCount   int          `yaml:\"node_count\"`\n\tAutoScaling *AutoScaling `yaml:\"auto_scaling,omitempty\"`\n}\n```\nGKENodePool defines a GKE node pool\n\n```go\ntype HTTPGetAction struct {\n\tPath string `yaml:\"path\"`\n\tPort int    `yaml:\"port\"`\n}\n```\nHTTPGetAction defines an HTTP GET probe\n\n```go\ntype HealthCheck struct {\n\tLiveness  *Probe `yaml:\"liveness,omitempty\"`\n\tReadiness *Probe `yaml:\"readiness,omitempty\"`\n}\n```\nHealthCheck defines health check configuration\n\n```go\ntype HelmHealthCheck struct {\n\tLiveness  HelmProbe `yaml:\"liveness\"`\n\tReadiness HelmProbe `yaml:\"readiness\"`\n}\n```\nHelmHealthCheck represents health check configuration\n\n```go\ntype HelmImageStorage struct {\n\tEnabled   bool          `yaml:\"enabled\"`\n\tType      string        `yaml:\"type\"`\n\tReplicas  int           `yaml:\"replicas\"`\n\tResources HelmResources `yaml:\"resources\"`\n\tStorage   HelmStorage   `yaml:\"storage\"`\n}\n```\nHelmImageStorage represents image storage configuration\n\n```go\ntype HelmProbe struct {\n\tPath                string `yaml:\"path\"`\n\tPort                int    `yaml:\"port\"`\n\tInitialDelaySeconds int    `yaml:\"initialDelaySeconds\"`\n\tPeriodSeconds       int    `yaml:\"periodSeconds\"`\n\tFailureThreshold    int    `yaml:\"failureThreshold,omitempty\"`\n}\n```\nHelmProbe represents a probe configuration\n\n```go\ntype HelmResourceLimits struct {\n\tMemory string `yaml:\"memory\"`\n\tCPU    string `yaml:\"cpu\"`\n}\n```\nHelmResourceLimits represents CPU/memory limits\n\n```go\ntype HelmResources struct {\n\tRequests HelmResourceLimits `yaml:\"requests\"`\n\tLimits   HelmResourceLimits `yaml:\"limits\"`\n}\n```\nHelmResources represents resource requests/limits\n\n```go\ntype HelmService struct {\n\tType        string `yaml:\"type\"`\n\tPort        int    `yaml:\"port\"`\n\tMetricsPort int    `yaml:\"metricsPort\"`\n}\n```\nHelmService represents service configuration\n\n```go\ntype HelmStackMeta struct {\n\tName    string `yaml:\"name\"`\n\tVersion string `yaml:\"version\"`\n}\n```\nHelmStackMeta represents stack metadata\n\n```go\ntype HelmStorage struct {\n\tClass string `yaml:\"class\"`\n\tSize  string `yaml:\"size\"`\n}\n```\nHelmStorage represents storage configuration\n\n```go\ntype HelmValues struct {\n\tStack        HelmStackMeta     `yaml:\"stack\"`\n\tVectorDB     HelmVectorDB      `yaml:\"vectordb\"`\n\tImageStorage *HelmImageStorage `yaml:\"imageStorage,omitempty\"`\n}\n```\nHelmValues represents the Helm values.yaml structure\n\n```go\nfunc GenerateHelmValues(config *StackConfig) (*HelmValues, error)\n```\nGenerateHelmValues generates Helm values.yaml from StackConfig\n\n```go\ntype HelmVectorDB struct {\n\tType      string          `yaml:\"type\"`\n\tVersion   string          `yaml:\"version\"`\n\tReplicas  int             `yaml:\"replicas\"`\n\tResources HelmResources   `yaml:\"resources\"`\n\tStorage   HelmStorage     `yaml:\"storage\"`\n\tService   HelmService     `yaml:\"service\"`\n\tHealth    HelmHealthCheck `yaml:\"health\"`\n}\n```\nHelmVectorDB represents VectorDB configuration for Helm\n\n```go\ntype ImageStorageConfig struct {\n\tType      string                `yaml:\"type\"` // \"minio\", \"s3\", \"local\"\n\tBucket    string                `yaml:\"bucket,omitempty\"`\n\tEndpoint  string                `yaml:\"endpoint,omitempty\"`\n\tResources *ResourceRequirements `yaml:\"resources,omitempty\"`\n}\n```\nImageStorageConfig defines image storage configuration\n\n```go\ntype InfrastructureConfig struct {\n\tVectorDB     VectorDBConfig      `yaml:\"vectordb\"`\n\tLLM          *LLMConfig          `yaml:\"llm,omitempty\"`\n\tImageStorage *ImageStorageConfig `yaml:\"image_storage,omitempty\"`\n}\n```\nInfrastructureConfig defines infrastructure components\n\n```go\ntype IngestCheckpoint struct {\n\tCollection     string       `json:\"collection\"`\n\tStartTime      time.Time    `json:\"start_time\"`\n\tLastUpdate     time.Time    `json:\"last_update\"`\n\tCompletedFiles []string     `json:\"completed_files\"`\n\tFailedFiles    []FailedFile `json:\"failed_files\"`\n\tPendingFiles   []string     `json:\"pending_files\"`\n}\n```\nIngestCheckpoint stores ingestion progress for resumability\n\n```go\nfunc InitCheckpoint(collection string, files []string, existingCheckpoint *IngestCheckpoint) *IngestCheckpoint\n```\nInitCheckpoint creates a new checkpoint from file list\n\n```go\nfunc LoadCheckpoint(path string) (*IngestCheckpoint, error)\n```\nLoadCheckpoint loads a checkpoint from disk\n\n```go\nfunc (c *IngestCheckpoint) GetFailedFile(file string) *FailedFile\n```\nGetFailedFile gets failed file info if exists\n\n```go\nfunc (c *IngestCheckpoint) MarkFileCompleted(file string)\n```\nMarkFileCompleted marks a file as completed in the checkpoint\n\n```go\nfunc (c *IngestCheckpoint) MarkFileFailed(file string, attempts int, errorMsg string)\n```\nMarkFileFailed marks a file as failed in the checkpoint\n\n```go\ntype IngestConfig struct {\n\tCollectionName   string\n\tDataPath         string\n\tType             string\n\tEmbeddingModel   string\n\tChunkSize        int\n\tParallelWorkers  int\n\tBatchSize        int\n\tMilvusLocalPort  int\n\tProgressCallback func(string)\n\tRestartEvery     int                  // Restart Milvus every N files (0 = no restart)\n\tRestartDelay     int                  // Seconds to wait after restart\n\tClusterInfo      *ClusterInfo         // Needed for restart\n\tPortForwardCtx   **PortForwardContext // Pointer to pointer so we can update it\n\tAutoRestart      bool                 // Automatically restart on failures\n\tMaxRetries       int                  // Maximum retry attempts (with auto-restart)\n\tResumeFrom       string               // Resume from specific file\n\tCheckpointEvery  int                  // Save checkpoint every N files\n\tCheckpointFile   string               // Path to checkpoint file\n\tSkipFailed       bool                 // Skip files that fail after max retries\n}\n```\nIngestConfig holds configuration for stack ingestion\n\n```go\ntype IngestionConfig struct {\n\tParallelWorkers int                               `yaml:\"parallel_workers,omitempty\"`\n\tBatchSize       int                               `yaml:\"batch_size,omitempty\"`\n\tRetry           *RetryConfig                      `yaml:\"retry,omitempty\"`\n\tTimeout         *TimeoutConfig                    `yaml:\"timeout,omitempty\"`\n\tCheckpoint      *CheckpointConfig                 `yaml:\"checkpoint,omitempty\"`\n\tMonitoring      *MonitoringConfig                 `yaml:\"monitoring,omitempty\"`\n\tPhases          []PhaseConfig                     `yaml:\"phases,omitempty\"`\n\tCollections     map[string]CollectionIngestConfig `yaml:\"collections,omitempty\"` // Per-collection ingestion\n}\n```\nIngestionConfig defines data ingestion pipeline\n\n```go\ntype IngestionState struct {\n\tPhase          string       `json:\"phase\"`\n\tCompletedFiles []string     `json:\"completed_files\"`\n\tFailedFiles    []FailedFile `json:\"failed_files,omitempty\"`\n\tCurrentFile    string       `json:\"current_file,omitempty\"`\n\tProgress       Progress     `json:\"progress\"`\n\tStartedAt      time.Time    `json:\"started_at\"`\n\tUpdatedAt      time.Time    `json:\"updated_at\"`\n}\n```\nIngestionState stores ingestion progress\n\n```go\ntype KindConfig struct {\n\tName   string `yaml:\"name\"`\n\tNodes  int    `yaml:\"nodes\"`\n\tConfig string `yaml:\"config,omitempty\"` // Custom Kind config YAML\n}\n```\nKindConfig is Kind-specific configuration\n\n```go\ntype KubernetesConfig struct {\n\tProvider string          `yaml:\"provider\"` // \"kind\", \"minikube\", \"eks\", \"gke\"\n\tKind     *KindConfig     `yaml:\"kind,omitempty\"`\n\tMinikube *MinikubeConfig `yaml:\"minikube,omitempty\"`\n\tEKS      *EKSConfig      `yaml:\"eks,omitempty\"`\n\tGKE      *GKEConfig      `yaml:\"gke,omitempty\"`\n}\n```\nKubernetesConfig defines K8s cluster configuration\n\n```go\ntype KubernetesResources struct {\n\tDeployment DeploymentConfig `yaml:\"deployment\"`\n}\n```\nKubernetesResources defines K8s-specific resource configuration\n\n```go\ntype LLMConfig struct {\n\tProvider string                 `yaml:\"provider\"` // \"openai\", \"anthropic\", \"ollama\"\n\tModels   LLMModels              `yaml:\"models\"`\n\tConfig   map[string]interface{} `yaml:\"config,omitempty\"`\n}\n```\nLLMConfig defines LLM provider configuration\n\n```go\ntype LLMModels struct {\n\tEmbedding string `yaml:\"embedding\"`\n\tChat      string `yaml:\"chat\"`\n}\n```\nLLMModels defines LLM model names\n\n```go\ntype LogOutput struct {\n\tType string `yaml:\"type\"` // \"file\", \"stdout\"\n\tPath string `yaml:\"path,omitempty\"`\n}\n```\nLogOutput defines a logging output\n\n```go\ntype LoggingConfig struct {\n\tLevel   string      `yaml:\"level\"`  // \"debug\", \"info\", \"warn\", \"error\"\n\tFormat  string      `yaml:\"format\"` // \"text\", \"json\"\n\tOutputs []LogOutput `yaml:\"outputs\"`\n}\n```\nLoggingConfig defines logging settings\n\n```go\ntype MinikubeConfig struct {\n\tDriver string   `yaml:\"driver\"` // \"podman\", \"docker\", \"kvm2\", \"hyperkit\"\n\tCPUs   int      `yaml:\"cpus\"`\n\tMemory string   `yaml:\"memory\"` // e.g., \"16384\" (MB)\n\tAddons []string `yaml:\"addons,omitempty\"`\n}\n```\nMinikubeConfig is Minikube-specific configuration\n\n```go\ntype MonitoringConfig struct {\n\tVDBHealthCheck  bool   `yaml:\"vdb_health_check,omitempty\"`\n\tRestartOnOOM    bool   `yaml:\"restart_on_oom,omitempty\"`\n\tMemoryThreshold string `yaml:\"memory_threshold,omitempty\"`\n}\n```\nMonitoringConfig defines monitoring settings\n\n```go\ntype OperationsConfig struct {\n\tLogging *LoggingConfig `yaml:\"logging,omitempty\"`\n\tCleanup *CleanupConfig `yaml:\"cleanup,omitempty\"`\n\tBackup  *BackupConfig  `yaml:\"backup,omitempty\"`\n}\n```\nOperationsConfig defines operational settings\n\n```go\ntype PM2Config struct {\n\tAppName          string            `yaml:\"app_name\"`\n\tScript           string            `yaml:\"script\"`             // Path to entry point (e.g., \"dist/index.js\")\n\tCwd              string            `yaml:\"cwd,omitempty\"`      // Working directory\n\tInstances        int               `yaml:\"instances\"`          // Number of instances (1 for most dashboards)\n\tMaxMemoryRestart string            `yaml:\"max_memory_restart\"` // e.g., \"1G\"\n\tAutorestart      bool              `yaml:\"autorestart\"`\n\tWatch            bool              `yaml:\"watch\"`\n\tErrorLog         string            `yaml:\"error_log\"`\n\tOutLog           string            `yaml:\"out_log\"`\n\tLogDateFormat    string            `yaml:\"log_date_format,omitempty\"`\n\tMergeLogs        bool              `yaml:\"merge_logs\"`\n\tMinUptime        string            `yaml:\"min_uptime\"`   // e.g., \"10s\"\n\tMaxRestarts      int               `yaml:\"max_restarts\"` // Max restarts within min_uptime\n\tKillTimeout      int               `yaml:\"kill_timeout\"` // Milliseconds\n\tEnv              map[string]string `yaml:\"env,omitempty\"`\n}\n```\nPM2Config defines PM2 process manager configuration\n\n```go\ntype PhaseConfig struct {\n\tName                   string   `yaml:\"name\"`\n\tCollections            []string `yaml:\"collections\"`\n\tParallel               bool     `yaml:\"parallel,omitempty\"`\n\tRestartVDBBetweenFiles bool     `yaml:\"restart_vdb_between_files,omitempty\"`\n}\n```\nPhaseConfig defines an ingestion phase\n\n```go\ntype PodInfo struct {\n\tName      string\n\tStatus    string\n\tReady     string\n\tRestarts  string\n\tAge       string\n\tComponent string\n}\n```\nPodInfo represents information about a Kubernetes pod\n\n```go\nfunc GetPods(selector, context string) ([]PodInfo, error)\n```\nGetPods gets pods matching selector\n\n```go\ntype PortForwardContext struct {\n\tLocalPort int\n\tCmd       *exec.Cmd\n\tCancel    context.CancelFunc\n}\n```\nPortForwardContext holds port forwarding context\n\n```go\nfunc StartMilvusPortForward(clusterInfo *ClusterInfo) (*PortForwardContext, error)\n```\nStartMilvusPortForward starts port forwarding to Milvus\n\n```go\nfunc (p *PortForwardContext) Stop()\n```\nStop stops the port forwarding\n\n```go\ntype Probe struct {\n\tHTTPGet             *HTTPGetAction `yaml:\"http_get,omitempty\"`\n\tInitialDelaySeconds int            `yaml:\"initial_delay_seconds,omitempty\"`\n\tPeriodSeconds       int            `yaml:\"period_seconds,omitempty\"`\n\tTimeoutSeconds      int            `yaml:\"timeout_seconds,omitempty\"`\n\tFailureThreshold    int            `yaml:\"failure_threshold,omitempty\"`\n}\n```\nProbe defines a K8s probe\n\n```go\ntype Progress struct {\n\tTotalFiles int `json:\"total_files\"`\n\tCompleted  int `json:\"completed\"`\n\tFailed     int `json:\"failed\"`\n\tRemaining  int `json:\"remaining\"`\n}\n```\nProgress represents ingestion progress\n\n```go\ntype ResourceLimits struct {\n\tMemory string `yaml:\"memory\"`\n\tCPU    string `yaml:\"cpu\"`\n}\n```\nResourceLimits defines resource limits\n\n```go\ntype ResourceRequirements struct {\n\tRequests ResourceLimits `yaml:\"requests\"`\n\tLimits   ResourceLimits `yaml:\"limits\"`\n}\n```\nResourceRequirements defines CPU and memory requirements\n\n```go\ntype RetryConfig struct {\n\tMaxAttempts int           `yaml:\"max_attempts\"`\n\tBackoff     string        `yaml:\"backoff\"` // \"constant\", \"exponential\"\n\tBaseDelay   time.Duration `yaml:\"base_delay,omitempty\"`\n}\n```\nRetryConfig defines retry behavior\n\n```go\ntype RuntimeConfig struct {\n\tKubernetes       KubernetesConfig `yaml:\"kubernetes\"`\n\tContainerRuntime string           `yaml:\"container_runtime\"` // \"podman\" or \"docker\"\n}\n```\nRuntimeConfig defines where the stack will run\n\n```go\ntype SchemaConfig struct {\n\tVectorDimensions int           `yaml:\"vector_dimensions\"`\n\tFields           []SchemaField `yaml:\"fields,omitempty\"`\n}\n```\nSchemaConfig defines collection schema\n\n```go\ntype SchemaField struct {\n\tName string `yaml:\"name\"`\n\tType string `yaml:\"type\"` // \"string\", \"int\", \"float\", \"text\", \"bool\"\n}\n```\nSchemaField defines a schema field\n\n```go\ntype ServiceStatus struct {\n\tName      string `json:\"name\"`\n\tStatus    string `json:\"status\"` // \"running\", \"stopped\", \"error\"\n\tHealth    string `json:\"health\"` // \"healthy\", \"unhealthy\", \"unknown\"\n\tUptime    string `json:\"uptime,omitempty\"`\n\tResources string `json:\"resources,omitempty\"`\n}\n```\nServiceStatus represents the status of a service\n\n```go\ntype StackConfig struct {\n\tVersion        string               `yaml:\"version\"`\n\tName           string               `yaml:\"name\"`\n\tDescription    string               `yaml:\"description,omitempty\"`\n\tRuntime        RuntimeConfig        `yaml:\"runtime\"`\n\tInfrastructure InfrastructureConfig `yaml:\"infrastructure\"`\n\tCollections    []CollectionConfig   `yaml:\"collections,omitempty\"`\n\tIngestion      *IngestionConfig     `yaml:\"ingestion,omitempty\"`\n\tDashboard      *DashboardConfig     `yaml:\"dashboard,omitempty\"`\n\tOperations     *OperationsConfig    `yaml:\"operations,omitempty\"`\n}\n```\nStackConfig represents the complete weave-stack.yaml configuration\n\n```go\nfunc LoadStackConfig(path string) (*StackConfig, error)\n```\nLoadStackConfig loads and parses weave-stack.yaml\n\n```go\ntype StackState struct {\n\tCluster   *ClusterInfo             `json:\"cluster,omitempty\"`\n\tServices  map[string]ServiceStatus `json:\"services\"`\n\tIngestion *IngestionState          `json:\"ingestion,omitempty\"`\n\tDashboard *DashboardState          `json:\"dashboard,omitempty\"`\n\tUpdatedAt time.Time                `json:\"updated_at\"`\n}\n```\nStackState stores the current state of the stack\n\n```go\ntype TimeoutConfig struct {\n\tPerFile time.Duration `yaml:\"per_file,omitempty\"`\n\tTotal   time.Duration `yaml:\"total,omitempty\"`\n}\n```\nTimeoutConfig defines timeout limits\n\n```go\ntype VectorDBConfig struct {\n\tType       string                 `yaml:\"type\"` // \"milvus\", \"qdrant\", \"weaviate\"\n\tVersion    string                 `yaml:\"version\"`\n\tKubernetes *KubernetesResources   `yaml:\"kubernetes,omitempty\"`\n\tResources  ResourceRequirements   `yaml:\"resources\"`\n\tConfig     map[string]interface{} `yaml:\"config,omitempty\"`\n\tHealth     *HealthCheck           `yaml:\"health,omitempty\"`\n}\n```\nVectorDBConfig defines vector database configuration\n\n```go\ntype WebDashboard struct {\n\tFramework  string               `yaml:\"framework\"` // \"nextjs\", \"react\", \"vue\"\n\tLanguage   string               `yaml:\"language\"`  // \"typescript\", \"javascript\"\n\tVersion    string               `yaml:\"version,omitempty\"`\n\tKubernetes *KubernetesResources `yaml:\"kubernetes,omitempty\"`\n\tFeatures   []string             `yaml:\"features,omitempty\"`\n\tAPI        []APIRoute           `yaml:\"api,omitempty\"`\n\tEnvFile    string               `yaml:\"env_file,omitempty\"`\n\tEnvVars    map[string]string    `yaml:\"env_vars,omitempty\"`\n\tBuild      *BuildConfig         `yaml:\"build,omitempty\"`\n\tDev        *DevConfig           `yaml:\"dev,omitempty\"`\n}\n```\nWebDashboard defines web dashboard configuration\n\n","path":"github.com/maximilien/weave-cli/src/pkg/stack","name":"stack","synopsis":"","isRedistributable":true}
