Documentation
¶
Index ¶
- Constants
- func GetActionReferences(cfg *app.AppConfig, action string) []refs.Ref
- func GetComponentReferences(cfg *app.AppConfig, comp string) []refs.Ref
- func GetFakeSandboxStackData(appCfg *app.AppConfig, region string, stateMap map[string]interface{}) map[string]any
- func GetStackReferences(cfg *app.AppConfig) []refs.Ref
- func IsEmail(email string) bool
- func PreloadAppActionWorkflowConfigs(db *gorm.DB) *gorm.DB
- func PreloadAppBreakGlassConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigComponentConfigConnections(db *gorm.DB) *gorm.DB
- func PreloadAppConfigInputConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigPermissionsConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigPolicyConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigRunnerConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigSandboxConfig(db *gorm.DB) *gorm.DB
- func PreloadAppConfigStackConfig(db *gorm.DB) *gorm.DB
- func PreloadAppOperationRoleConfig(db *gorm.DB) *gorm.DB
- func PreloadAppSecretsConfig(db *gorm.DB) *gorm.DB
- func PreloadComponentConfigConnections(db *gorm.DB) *gorm.DB
- type CreateAppBranchRunRequest
- type Helpers
- func (h *Helpers) CliVerisionAllowed(ctx context.Context, version string) (bool, error)
- func (h *Helpers) CreateAppBranch(ctx context.Context, appID string, name string) (*app.AppBranch, error)
- func (h *Helpers) CreateAppBranchConfig(ctx context.Context, appBranchID string, ...) (*app.AppBranchConfig, error)
- func (h *Helpers) CreateAppBranchRun(ctx context.Context, req *CreateAppBranchRunRequest) (*app.AppBranchRun, error)
- func (h *Helpers) CreateAppSandboxQueue(ctx context.Context, appID string) error
- func (s *Helpers) CreateAppWorkflow(ctx context.Context, appID string, workflowType app.WorkflowType, ...) (*app.Workflow, error)
- func (s *Helpers) CreateWorkflow(ctx context.Context, appBranchID string, workflowType app.WorkflowType, ...) (*app.Workflow, error)
- func (s *Helpers) DeleteAppComponent(ctx context.Context, compID string) error
- func (h *Helpers) EnsureAppBranchQueue(ctx context.Context, branchID string) error
- func (h *Helpers) EnsureAppQueue(ctx context.Context, appID string) error
- func (h *Helpers) FetchAppBranchesWithConfigs(ctx context.Context, appID string) ([]app.AppBranch, error)
- func (s *Helpers) GetAppComponents(ctx context.Context, appID string) ([]app.Component, error)
- func (h *Helpers) GetAppComponentsAtConfigVersion(ctx context.Context, appID string, appCfgVersion int, componentIDs []string) ([]app.Component, error)
- func (s *Helpers) GetAppInstalls(ctx context.Context, appID string) ([]app.Install, error)
- func (h *Helpers) GetAppLatestConfig(ctx context.Context, appID string) (*app.AppConfig, error)
- func (h *Helpers) GetComponentDependents(ctx context.Context, appCfgID string, compID string) ([]string, error)
- func (s *Helpers) GetComponents(ctx context.Context, compIDs []string) ([]app.Component, error)
- func (h *Helpers) GetConfigComponentDeployOrder(ctx context.Context, cfg *app.AppConfig, compID string) ([]string, error)
- func (h *Helpers) GetConfigDefaultComponentOrder(ctx context.Context, cfg *app.AppConfig) ([]string, error)
- func (h *Helpers) GetConfigGraph(ctx context.Context, cfg *app.AppConfig) (graph.Graph[string, *app.Component], error)
- func (h *Helpers) GetConfigReverseDefaultComponentOrder(ctx context.Context, cfg *app.AppConfig) ([]string, error)
- func (h *Helpers) GetFullAppConfig(ctx context.Context, appConfigID string, skipAdditionalChecks bool) (*app.AppConfig, error)
- func (h *Helpers) GetPoliciesConfigByAppConfigID(ctx context.Context, appConfigID string) (*app.AppPoliciesConfig, error)
- func (h *Helpers) GetReverseConfigComponentDeployOrder(ctx context.Context, cfg *app.AppConfig, compID string) ([]string, error)
- func (h *Helpers) VCSHelpers() *vcshelpers.Helpers
- func (h *Helpers) ValidateGraph(ctx context.Context, appID string) error
- func (h *Helpers) ValidateSameRepo(branches []app.AppBranch, vcsConfigReq *vcshelpers.VCSConfigRequest) error
- type Params
Constants ¶
const ( AppWorkflowsQueueName = "app-workflows" AppSignalsQueueName = "app-signals" AppWorkflowStepGroupsQueueName = "app-workflow-step-groups" AppWorkflowStepsQueueName = "app-workflow-steps" )
Variables ¶
This section is empty.
Functions ¶
func GetComponentReferences ¶
NOTE(jm): this is a function, because it is used directly within a workflow.
func GetFakeSandboxStackData ¶ added in v0.19.850
func GetFakeSandboxStackData(appCfg *app.AppConfig, region string, stateMap map[string]interface{}) map[string]any
GetFakeSandboxStackData builds a fake stack output map for sandbox mode orgs, using real keys from the app config with random fake values. stateMap is used to render templated role names (e.g. "{{.install.name}}-admin"). NOTE: this is a standalone function because it is used directly within workflows.
func PreloadAppActionWorkflowConfigs ¶
preload action workflow configs
func PreloadAppBreakGlassConfig ¶
break glass config
func PreloadAppConfigComponentConfigConnections ¶
component config connections
func PreloadAppConfigInputConfig ¶
input config
func PreloadAppConfigPermissionsConfig ¶
permissions config
func PreloadAppConfigPolicyConfig ¶
policies config
func PreloadAppConfigRunnerConfig ¶
runner config
func PreloadAppConfigSandboxConfig ¶
sandbox config
func PreloadAppConfigStackConfig ¶
cloudformation stack config
func PreloadAppOperationRoleConfig ¶ added in v0.19.807
component role config
Types ¶
type CreateAppBranchRunRequest ¶ added in v0.19.850
type Helpers ¶
type Helpers struct {
// contains filtered or unexported fields
}
func (*Helpers) CliVerisionAllowed ¶
func (*Helpers) CreateAppBranch ¶
func (*Helpers) CreateAppBranchConfig ¶ added in v0.19.850
func (h *Helpers) CreateAppBranchConfig( ctx context.Context, appBranchID string, connectedGithubVCSConfig *app.ConnectedGithubVCSConfig, publicGitVCSConfig *app.PublicGitVCSConfig, installGroups []app.AppBranchInstallGroup, ) (*app.AppBranchConfig, error)
func (*Helpers) CreateAppBranchRun ¶ added in v0.19.850
func (h *Helpers) CreateAppBranchRun(ctx context.Context, req *CreateAppBranchRunRequest) (*app.AppBranchRun, error)
func (*Helpers) CreateAppSandboxQueue ¶ added in v0.19.850
CreateAppSandboxQueue creates a Temporal queue for the app's sandbox build workflow. This enables sandbox-build signals to be enqueued and processed against the app.
func (*Helpers) CreateAppWorkflow ¶ added in v0.19.903
func (*Helpers) CreateWorkflow ¶
func (*Helpers) DeleteAppComponent ¶
func (*Helpers) EnsureAppBranchQueue ¶ added in v0.19.850
EnsureAppBranchQueue creates a Temporal queue workflow for the given app branch. Safe to call multiple times — queueClient.Create is idempotent.
func (*Helpers) EnsureAppQueue ¶ added in v0.19.903
EnsureAppQueue creates all Temporal queue workflows needed for an app to execute workflows through the shared flow infrastructure. Safe to call multiple times — queueClient.Create is idempotent.
func (*Helpers) FetchAppBranchesWithConfigs ¶ added in v0.19.850
func (h *Helpers) FetchAppBranchesWithConfigs(ctx context.Context, appID string) ([]app.AppBranch, error)
FetchAppBranchesWithConfigs retrieves all app branches for an app with their configs preloaded
func (*Helpers) GetAppComponents ¶
func (*Helpers) GetAppComponentsAtConfigVersion ¶
func (h *Helpers) GetAppComponentsAtConfigVersion(ctx context.Context, appID string, appCfgVersion int, componentIDs []string) ([]app.Component, error)
This returns all app components for a point in time
func (*Helpers) GetAppInstalls ¶
func (*Helpers) GetAppLatestConfig ¶
func (*Helpers) GetComponentDependents ¶
func (*Helpers) GetComponents ¶
func (*Helpers) GetConfigComponentDeployOrder ¶
func (*Helpers) GetConfigDefaultComponentOrder ¶
func (*Helpers) GetConfigGraph ¶
func (h *Helpers) GetConfigGraph(ctx context.Context, cfg *app.AppConfig) (graph.Graph[string, *app.Component], error)
GetConfigGraph builds a directed acyclic graph of component dependencies and returns both the graph and a sorted list of components in deployment order (dependencies first)
func (*Helpers) GetConfigReverseDefaultComponentOrder ¶
func (*Helpers) GetFullAppConfig ¶
func (*Helpers) GetPoliciesConfigByAppConfigID ¶
func (*Helpers) GetReverseConfigComponentDeployOrder ¶
func (*Helpers) VCSHelpers ¶ added in v0.19.850
func (h *Helpers) VCSHelpers() *vcshelpers.Helpers
VCSHelpers returns the VCS helpers for git source resolution and token creation.
func (*Helpers) ValidateGraph ¶
func (*Helpers) ValidateSameRepo ¶ added in v0.19.850
func (h *Helpers) ValidateSameRepo( branches []app.AppBranch, vcsConfigReq *vcshelpers.VCSConfigRequest, ) error
ValidateSameRepo validates that all app branches use the same repository as the provided request Accepts the VCS config request (before creation) to validate early If both publicRepoReq and connectedRepoReq are nil, returns early with no validation Branches with no VCS config (both nil) are ignored during validation
Source Files
¶
- create_app_branch.go
- create_app_branch_config.go
- create_app_branch_run.go
- create_app_sandbox_queue.go
- create_workflow.go
- delete_app_component.go
- ensure_app_branch_queue.go
- ensure_app_queue.go
- get_app_components.go
- get_components.go
- get_components_by_app_config_version.go
- get_config.go
- get_config_graph.go
- get_dependents.go
- get_fake_sandbox_stack_data.go
- get_full_config.go
- get_graph.go
- get_policies_config.go
- get_references.go
- helpers.go
- is_email.go
- order.go
- scopes.go
- validate_app_branch_repo.go
- validate_graph.go