Documentation
¶
Index ¶
Constants ¶
View Source
const ( DEVELOPMENT_ENV = "DEVELOPMENT" PRODUCTION_ENV = "PRODUCTION" )
Selectable values of STACKDOME_ENV. The test environment is not selectable here: it needs a session factory injected by the test bootstrap.
Variables ¶
This section is empty.
Functions ¶
func GetEnvironmentStrFromEnv ¶
func GetEnvironmentStrFromEnv() string
Types ¶
type ApplicationConfigOption ¶
type ApplicationConfigOption func(*config.ApplicationConfig)
func (ApplicationConfigOption) ApplyToEnv ¶
func (o ApplicationConfigOption) ApplyToEnv(env *Env)
type Env ¶
type Env struct {
Name string
Services Services
DBSession db.SessionFactory
Config *config.ApplicationConfig
PlatformConfig *config.PlatformConfig
Clients Clients
ClusterManager clustermanager.ClusterManager
WorkerManager workermanager.WorkerManager
ResourceAccessPolicyManager resourceaccess.ResourceAccessPolicyManager
PermissionService auth.PermissionService
RefreshTokenStore stores.RefreshTokenStore
OAuthStateStore stores.OAuthStateStore
EmailService emailpkg.EmailService
LeadershipFlag *leadership.Flag
EncryptionService services.EncryptionService
ComputePolicy computequota.Policy
PasswordSignupProtection signupprotection.PasswordSignupProtection
SignupClientIPResolver signupprotection.ClientIPResolver
Logger applogger.Logger
Observability *observability.Metrics
}
type EnvConfigOption ¶
type EnvConfigOption interface {
ApplyToEnv(env *Env)
}
func WithApplicationConfig ¶
func WithApplicationConfig(cfg *config.ApplicationConfig) EnvConfigOption
func WithPlatformConfig ¶
func WithPlatformConfig(cfg *config.PlatformConfig) EnvConfigOption
type EnvImpl ¶
type EnvImpl interface {
Init(context.Context) error
InitDatabase(context.Context) error
Environment() *Env
Shutdown(context.Context) error
}
func NewTestEnvironment ¶
func NewTestEnvironment(sessionFactory db.SessionFactory, opts ...EnvConfigOption) EnvImpl
type PlatformConfigOption ¶
type PlatformConfigOption func(*config.PlatformConfig)
func (PlatformConfigOption) ApplyToEnv ¶
func (o PlatformConfigOption) ApplyToEnv(env *Env)
type Services ¶
type Services struct {
UserService services.UserService
OrganisationService services.OrganisationService
ClusterService services.ClusterService
StackStorageService services.StackStorageService
VolumeService services.VolumeService
StackService services.StackService
StackResourceService services.StackResourceService
ImageBuildService services.ImageBuildService
ClusterImageRegistryService services.ImageRegistryService
StackDomainService services.StackDomainsService
OrganisationDomainService services.OrganisationDomainsService
NamespaceService services.NamespaceService
LoggingService services.LoggingService
MetricsService services.MetricsService
SecretService services.SecretService
CredentialResolver services.CredentialResolver
RegistryCredentialService services.RegistryCredentialService
GitIntegrationService services.GitIntegrationService
GitHubWebhookService services.GitHubWebhookService
EncryptionService services.EncryptionService
ObjectStoreService services.ObjectStoreService
PostgresAddonService services.PostgresAddonService
PostgresBackupService services.PostgresBackupService
APITokenService services.APITokenService
ProjectService services.ProjectService
OrgInviteService services.OrgInviteService
SignupService services.SignupService
StackReleaseService services.StackReleaseService
ReleaseEventRecorder services.ReleaseEventRecorder
ReferenceService services.ReferenceService
StackPreviewConfigService services.StackPreviewConfigService
PreviewStackService services.PreviewStackService
}
Click to show internal directories.
Click to hide internal directories.