orchestrator

package
v0.0.0-...-4c964c4 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

WireSet provides a wire set for this package.

Functions

This section is empty.

Types

type Config

type Config struct {
	DefaultBaseImage string
}

type Orchestrator

type Orchestrator interface {
	// TriggerStartGitspace fetches the infra resources configured for the gitspace and triggers the infra provisioning.
	TriggerStartGitspace(ctx context.Context, gitspaceConfig types.GitspaceConfig) error

	// ResumeStartGitspace saves the provisioned infra, resolves the code repo details & creates the Gitspace container.
	ResumeStartGitspace(
		ctx context.Context,
		gitspaceConfig types.GitspaceConfig,
		provisionedInfra types.Infrastructure,
	) (types.GitspaceInstance, error)

	// TriggerStopGitspace stops the Gitspace container and triggers infra deprovisioning to deprovision
	// all the infra resources which are not required to restart the Gitspace.
	TriggerStopGitspace(ctx context.Context, gitspaceConfig types.GitspaceConfig) error

	// ResumeStopGitspace saves the deprovisioned infra details.
	ResumeStopGitspace(
		ctx context.Context,
		gitspaceConfig types.GitspaceConfig,
		stoppedInfra types.Infrastructure,
	) (enum.GitspaceInstanceStateType, error)

	// TriggerDeleteGitspace removes the Gitspace container and triggers infra deprovisioning to deprovision
	// all the infra resources.
	TriggerDeleteGitspace(ctx context.Context, gitspaceConfig types.GitspaceConfig) error

	// ResumeDeleteGitspace saves the deprovisioned infra details.
	ResumeDeleteGitspace(
		ctx context.Context,
		gitspaceConfig types.GitspaceConfig,
		deprovisionedInfra types.Infrastructure,
	) (enum.GitspaceInstanceStateType, error)

	// GetGitspaceLogs fetches gitspace's start/stop logs.
	GetGitspaceLogs(ctx context.Context, gitspaceConfig types.GitspaceConfig) (string, error)
}

func NewOrchestrator

func NewOrchestrator(
	scm scm.SCM,
	infraProviderResourceStore store.InfraProviderResourceStore,
	infraProvisioner infrastructure.InfraProvisioner,
	containerOrchestrator container.Orchestrator,
	eventReporter *events.Reporter,
	config *Config,
	vsCodeService *ide.VSCode,
	vsCodeWebService *ide.VSCodeWeb,
	secretResolverFactory *secret.ResolverFactory,
) Orchestrator

func ProvideOrchestrator

func ProvideOrchestrator(
	scm scm.SCM,
	infraProviderResourceStore store.InfraProviderResourceStore,
	infraProvisioner infrastructure.InfraProvisioner,
	containerOrchestrator container.Orchestrator,
	reporter *events.Reporter,
	config *Config,
	vsCodeService *ide.VSCode,
	vsCodeWebService *ide.VSCodeWeb,
	secretResolverFactory *secret.ResolverFactory,
) Orchestrator

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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