app

package
v0.18.7 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialize added in v0.18.0

func Initialize()

func IsDevEnvironment added in v0.17.0

func IsDevEnvironment() bool

IsDevEnvironment returns true if the application is running in a development environment.

func IsShuttingDown

func IsShuttingDown() bool

IsShuttingDown returns true if the application is in the process of a graceful shutdown.

func KubernetesNamespace added in v0.18.0

func KubernetesNamespace() (string, bool)

func ModusHomeDir added in v0.17.0

func ModusHomeDir() string

func ProductVersion added in v0.17.0

func ProductVersion() string

func SetConfig added in v0.17.0

func SetConfig(c *AppConfig)

SetConfig sets the global app configuration. This is typically only called in tests.

func SetOutputColorMode added in v0.17.0

func SetOutputColorMode()

SetOutputColorMode applies the FORCE_COLOR environment variable to override the default color mode.

func SetShuttingDown

func SetShuttingDown()

SetShuttingDown sets the application to a shutting down state during a graceful shutdown.

func VersionNumber added in v0.17.0

func VersionNumber() string

Types

type AppConfig added in v0.17.0

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

func Config added in v0.17.0

func Config() *AppConfig

Config returns the global app configuration.

func CreateAppConfig added in v0.17.0

func CreateAppConfig() *AppConfig

Creates the app configuration from the command line flags and environment variables.

func NewAppConfig added in v0.17.0

func NewAppConfig() *AppConfig

Creates a new AppConfig instance with default values.

func (*AppConfig) AppPath added in v0.17.0

func (c *AppConfig) AppPath() string

func (*AppConfig) Environment added in v0.17.0

func (c *AppConfig) Environment() string

func (*AppConfig) IsDevEnvironment added in v0.17.0

func (c *AppConfig) IsDevEnvironment() bool

func (*AppConfig) KubernetesSecretName added in v0.18.0

func (c *AppConfig) KubernetesSecretName() string

func (*AppConfig) Port added in v0.17.0

func (c *AppConfig) Port() int

func (*AppConfig) RefreshInterval added in v0.17.0

func (c *AppConfig) RefreshInterval() time.Duration

func (*AppConfig) S3Bucket added in v0.17.0

func (c *AppConfig) S3Bucket() string

func (*AppConfig) S3Path added in v0.17.0

func (c *AppConfig) S3Path() string

func (*AppConfig) UseAwsStorage added in v0.17.0

func (c *AppConfig) UseAwsStorage() bool

func (*AppConfig) UseJsonLogging added in v0.17.0

func (c *AppConfig) UseJsonLogging() bool

func (*AppConfig) UseKubernetesSecret added in v0.18.0

func (c *AppConfig) UseKubernetesSecret() bool

func (*AppConfig) WithAppPath added in v0.17.0

func (c *AppConfig) WithAppPath(appPath string) *AppConfig

func (*AppConfig) WithEnvironment added in v0.17.0

func (c *AppConfig) WithEnvironment(environment string) *AppConfig

func (*AppConfig) WithJsonLogging added in v0.17.0

func (c *AppConfig) WithJsonLogging() *AppConfig

func (*AppConfig) WithPort added in v0.17.0

func (c *AppConfig) WithPort(port int) *AppConfig

func (*AppConfig) WithRefreshInterval added in v0.17.0

func (c *AppConfig) WithRefreshInterval(interval time.Duration) *AppConfig

func (*AppConfig) WithS3Storage added in v0.17.0

func (c *AppConfig) WithS3Storage(s3Bucket, s3Path string) *AppConfig

Jump to

Keyboard shortcuts

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