Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadBlueprintIfTerraformProject ¶ added in v0.9.1
func LoadBlueprintIfTerraformProject(rt *runtime.Runtime, skipValidation bool, opts ...*Composer) error
LoadBlueprintIfTerraformProject composes the blueprint when terraform is enabled and the project has terraform components. It skips composition otherwise. A component's inputs can reference another component's output through terraform_output(...). Callers that load environment variables must run this first. opts overrides the constructed Composer's dependencies, the same as NewComposer.
Types ¶
type Composer ¶
type Composer struct {
// Resource-specific dependencies
ArtifactBuilder artifact.Artifact
BlueprintHandler blueprint.BlueprintHandler
TerraformResolver terraform.ModuleResolver
// contains filtered or unexported fields
}
Composer holds the execution context for resource operations. It includes all resource-specific dependencies and core runtime dependencies.
func NewComposer ¶
NewComposer creates and initializes a new Composer instance with the provided execution context. It sets up all required resource handlers—artifact builder, blueprint handler, and terraform resolver. If overrides are provided, any non-nil component in the override Composer will be used instead of creating a default. Panics if runtime or any required dependencies are nil.
func (*Composer) Bundle ¶
Bundle creates a complete artifact bundle from the project's templates, kustomize, and terraform files. It creates a distributable artifact. The outputPath specifies where to save the bundle file. Returns the actual output path or an error.
func (*Composer) Generate ¶
Generate processes and deploys the complete project infrastructure. It initializes all core resources, processes blueprints, and handles terraform modules for the project. The optional overwrite parameter determines whether existing files should be overwritten during blueprint processing. The optional blueprintURL parameter specifies the blueprint artifact to load (OCI URL or local .tar.gz path). If not provided, LoadBlueprint will use the default blueprint URL. This is the main deployment method. Returns an error if any initialization or processing step fails.
func (*Composer) Push ¶
Push creates and pushes an artifact to a container registry. It bundles all project files and pushes them to the specified registry with the given tag. The registryURL can be in formats like "registry.com/repo:tag", "registry.com/repo", or "oci://registry.com/repo:tag". Returns the registry URL or an error.