mirror of
https://github.com/hanzoai/o11y-foundry.git
synced 2026-10-30 18:26:45 +00:00
21 lines
761 B
Go
21 lines
761 B
Go
package infrastructure
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/hanzoai/o11y-foundry/api/v1alpha1/installation"
|
|
"github.com/hanzoai/o11y-foundry/internal/domain"
|
|
)
|
|
|
|
// Generator is the interface for infrastructure-as-code generators.
|
|
// Implementations produce IaC manifests (e.g., Terraform, Pulumi) from a casting configuration
|
|
// and can validate the generated output using the underlying tool.
|
|
type Generator interface {
|
|
// Generate produces IaC materials from the casting configuration.
|
|
Generate(ctx context.Context, config installation.Casting) ([]domain.Material, error)
|
|
|
|
// Validate runs the IaC tool's built-in validation (e.g., terraform validate)
|
|
// against the manifests written to poursPath.
|
|
Validate(ctx context.Context, poursPath string) error
|
|
}
|