Documentation ¶
Index ¶
- Variables
- func NewBicepProvider(azCli azcli.AzCli, bicepCli *bicep.Cli, resourceService *azapi.ResourceService, ...) provisioning.Provider
- type BicepProvider
- func (p *BicepProvider) Deploy(ctx context.Context) (*provisioning.DeployResult, error)
- func (p *BicepProvider) Destroy(ctx context.Context, options provisioning.DestroyOptions) (*provisioning.DestroyResult, error)
- func (p *BicepProvider) EnsureEnv(ctx context.Context) error
- func (p *BicepProvider) Initialize(ctx context.Context, projectPath string, options provisioning.Options) error
- func (p *BicepProvider) LastDeployment(ctx context.Context) (*azapi.ResourceDeployment, error)
- func (p *BicepProvider) Name() string
- func (p *BicepProvider) Preview(ctx context.Context) (*provisioning.DeployPreviewResult, error)
- func (p *BicepProvider) RequiredExternalTools() []tools.ExternalTool
- func (p *BicepProvider) State(ctx context.Context, options *provisioning.StateOptions) (*provisioning.StateResult, error)
Constants ¶
This section is empty.
Variables ¶
var ErrEnsureEnvPreReqBicepCompileFailed = errors.New("")
Functions ¶
func NewBicepProvider ¶
func NewBicepProvider( azCli azcli.AzCli, bicepCli *bicep.Cli, resourceService *azapi.ResourceService, deploymentManager *infra.DeploymentManager, envManager environment.Manager, env *environment.Environment, console input.Console, prompters prompt.Prompter, curPrincipal provisioning.CurrentPrincipalIdProvider, keyvaultService keyvault.KeyVaultService, cloud *cloud.Cloud, ) provisioning.Provider
NewBicepProvider creates a new instance of a Bicep Infra provider
Types ¶
type BicepProvider ¶
type BicepProvider struct {
// contains filtered or unexported fields
}
BicepProvider exposes infrastructure provisioning using Azure Bicep templates
func (*BicepProvider) Deploy ¶
func (p *BicepProvider) Deploy(ctx context.Context) (*provisioning.DeployResult, error)
Provisioning the infrastructure within the specified template
func (*BicepProvider) Destroy ¶
func (p *BicepProvider) Destroy( ctx context.Context, options provisioning.DestroyOptions, ) (*provisioning.DestroyResult, error)
Destroys the specified deployment by deleting all azure resources, resource groups & deployments that are referenced.
func (*BicepProvider) EnsureEnv ¶
func (p *BicepProvider) EnsureEnv(ctx context.Context) error
EnsureEnv ensures that the environment is in a provision-ready state with required values set, prompting the user if values are unset. This also requires that the Bicep module can be compiled.
func (*BicepProvider) Initialize ¶
func (p *BicepProvider) Initialize(ctx context.Context, projectPath string, options provisioning.Options) error
Initialize initializes provider state from the options. It also calls EnsureEnv, which ensures the client-side state is ready for provisioning.
func (*BicepProvider) LastDeployment ¶
func (p *BicepProvider) LastDeployment(ctx context.Context) (*azapi.ResourceDeployment, error)
func (*BicepProvider) Name ¶
func (p *BicepProvider) Name() string
Name gets the name of the infra provider
func (*BicepProvider) Preview ¶
func (p *BicepProvider) Preview(ctx context.Context) (*provisioning.DeployPreviewResult, error)
Preview runs deploy using the what-if argument
func (*BicepProvider) RequiredExternalTools ¶
func (p *BicepProvider) RequiredExternalTools() []tools.ExternalTool
func (*BicepProvider) State ¶
func (p *BicepProvider) State(ctx context.Context, options *provisioning.StateOptions) (*provisioning.StateResult, error)