Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Execute ¶
func Execute() error
Execute adds all child commands to the root command and sets flags appropriately.
func ProvideConfig ¶
ProvideConfig converts the CLIConfig to an application Config.
Types ¶
type CLIConfig ¶
CLIConfig wraps the application config with CLI-specific settings.
func LoadCLIConfig ¶
func LoadCLIConfig() *CLIConfig
LoadCLIConfig creates a CLIConfig from environment and defaults.
func (*CLIConfig) UpdateFromFlags ¶
UpdateFromFlags applies CLI flag overrides to the configuration.
type Dependencies ¶
type Dependencies struct {
ResourceTypeService application.ResourceTypeService
ResourceService application.ResourceService
App *fx.App
}
Dependencies holds all the dependencies needed by CLI commands.
func StartContainer ¶
func StartContainer(cliCfg *CLIConfig) (*Dependencies, error)
StartContainer starts the Fx container and returns dependencies.
func StartContainerWithDSN ¶
func StartContainerWithDSN(dsn string) (*Dependencies, error)
StartContainerWithDSN starts the Fx container with the given database DSN. Useful for E2E in-process testing so tests run in the same process.
func (*Dependencies) Shutdown ¶
func (d *Dependencies) Shutdown() error
Shutdown gracefully shuts down the Fx container.