discovery

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListAvailableServices

func ListAvailableServices() ([]string, error)

ListAvailableServices scans app/*/service directories and returns service names.

func NormalizeServiceName

func NormalizeServiceName(arg string) string

NormalizeServiceName extracts a bare service name from a single path argument.

func NormalizeServiceNames

func NormalizeServiceNames(args []string) []string

NormalizeServiceNames extracts bare service names from paths that may result from shell tab-completion (e.g. "app/servora/service/" → "servora").

func ValidateConfigExists

func ValidateConfigExists(serviceName string) error

ValidateConfigExists checks that configs/local/ directory exists for the service.

func ValidateDatabaseConfig

func ValidateDatabaseConfig(bc *conf.Bootstrap) error

ValidateDatabaseConfig checks that the bootstrap has a database config.

func ValidateServiceExists

func ValidateServiceExists(serviceName string) error

ValidateServiceExists checks that the service directory exists.

Types

type ServiceConfig

type ServiceConfig struct {
	Name      string
	Path      string
	Bootstrap *conf.Bootstrap
}

ServiceConfig holds resolved configuration for a service.

func LoadServiceConfig

func LoadServiceConfig(serviceName string) (*ServiceConfig, error)

LoadServiceConfig loads the bootstrap config for the given service.

Jump to

Keyboard shortcuts

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