internal

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AzureServicePlanResourceName

func AzureServicePlanResourceName(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)

AzureServicePlanResourceName Retrieve the resource name for a Azure app service plan. The reason to make this conditional is because of backwards compatability; existing environments already have a `functionapp` resource. We want to keep that intact.

func NewAzurePlugin

func NewAzurePlugin() schema.MachComposerPlugin

Types

type AzureTFState

type AzureTFState struct {
	ResourceGroup  string `mapstructure:"resource_group"`
	StorageAccount string `mapstructure:"storage_account"`
	ContainerName  string `mapstructure:"container_name"`
	StateFolder    string `mapstructure:"state_folder"`
}

AzureTFState Azure storage account state backend configuration.

func (AzureTFState) Key

func (a AzureTFState) Key(site string) string

type ComponentConfig

type ComponentConfig struct {
	Endpoints map[string]string `mapstructure:"-"`

	Name        string `mapstructure:"-"`
	ServicePlan string `mapstructure:"service_plan"`
	ShortName   string `mapstructure:"short_name"`
}

type GlobalConfig

type GlobalConfig struct {
	TenantID       string            `mapstructure:"tenant_id"`
	SubscriptionID string            `mapstructure:"subscription_id"`
	ResourceGroup  string            `mapstructure:"resource_group"`
	ResourcePrefix string            `mapstructure:"resource_prefix"`
	ResourceTags   map[string]string `mapstructure:"resource_tags"`
}

type Plugin

type Plugin struct {
	// contains filtered or unexported fields
}

func (*Plugin) Configure

func (p *Plugin) Configure(environment string, provider string) error

func (*Plugin) GetValidationSchema

func (p *Plugin) GetValidationSchema() (*schema.ValidationSchema, error)

func (*Plugin) IsEnabled

func (p *Plugin) IsEnabled() bool

func (*Plugin) RenderTerraformComponent

func (p *Plugin) RenderTerraformComponent(site string, component string) (*schema.ComponentSchema, error)

func (*Plugin) SetComponentConfig

func (p *Plugin) SetComponentConfig(component string, data map[string]any) error

func (*Plugin) SetGlobalConfig

func (p *Plugin) SetGlobalConfig(data map[string]any) error

func (*Plugin) SetRemoteStateBackend

func (p *Plugin) SetRemoteStateBackend(data map[string]any) error

func (*Plugin) SetSiteComponentConfig

func (p *Plugin) SetSiteComponentConfig(site, component string, data map[string]any) error

func (*Plugin) SetSiteConfig

func (p *Plugin) SetSiteConfig(site string, data map[string]any) error

func (*Plugin) TerraformRenderProviders

func (p *Plugin) TerraformRenderProviders(site string) (string, error)

func (*Plugin) TerraformRenderResources

func (p *Plugin) TerraformRenderResources(site string) (string, error)

func (*Plugin) TerraformRenderStateBackend

func (p *Plugin) TerraformRenderStateBackend(site string) (string, error)

type SiteComponent

type SiteComponent struct {
	InternalName string
	ExternalName string
	Component    *ComponentConfig
}

type SiteComponentConfig

type SiteComponentConfig struct {
	ServicePlan string `mapstructure:"service_plan"`

	Name      string           `mapstructure:"-"`
	Component *ComponentConfig `mapstructure:"-"`
}

type SiteConfig

type SiteConfig struct {
	ResourceGroup  string `mapstructure:"resource_group"`
	ResourcePrefix string `mapstructure:"resource_prefix"`
	SubscriptionID string `mapstructure:"subscription_id"`

	Components map[string]SiteComponentConfig
}

Jump to

Keyboard shortcuts

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