Documentation ¶
Index ¶
- Constants
- Variables
- func AttributePathError(err error, attributeNames ...string) error
- func Server() tfprotov6.ProviderServer
- func ValidationError(msg string, attributeNames ...string) error
- func WithDefaultDataRouter(overrides ...dr.DataSource) func(server.Server) server.Server
- func WithDefaultResourceRouter(overrides ...rr.Resource) func(server.Server) server.Server
- type FailureHandler
- type Provider
- func (p *Provider) Config() tftypes.Value
- func (p *Provider) Configure(ctx context.Context, req *tfprotov6.ConfigureProviderRequest) (*tfprotov6.ConfigureProviderResponse, error)
- func (p *Provider) MetaSchema() *tfprotov6.Schema
- func (p *Provider) Schema() *tfprotov6.Schema
- func (p *Provider) Stop(ctx context.Context, req *tfprotov6.StopProviderRequest) (*tfprotov6.StopProviderResponse, error)
- func (p *Provider) Validate(ctx context.Context, req *tfprotov6.ValidateProviderConfigRequest) (*tfprotov6.ValidateProviderConfigResponse, error)
- type ResourceWithProviderConfig
- type StateWithTransport
- type TFType
- type Transports
Constants ¶
const ( UNKNOWN it.TransportType = "unknown" SSH it.TransportType = "ssh" K8S it.TransportType = "kubernetes" NOMAD it.TransportType = "nomad" )
Variables ¶
var TransportTypes = []it.TransportType{SSH, K8S, NOMAD}
Functions ¶
func AttributePathError ¶
func Server ¶
func Server() tfprotov6.ProviderServer
Server returns a default instance of our ProviderServer.
func ValidationError ¶
ValidationError creates a tftypes.AttributePathError, with the error message formatted as follows: "validation error, <msg>" The attributeNames represent the steps in the path to the attribute that failed validation.
func WithDefaultDataRouter ¶
WithDefaultDataRouter creates a server opt that registers all the default datasources and optionally any provided overrides (or additional, non-default resources). The optional overrides argument is useful if you need to override a datasource in a test.
func WithDefaultResourceRouter ¶
WithDefaultResourceRouter creates a server opt that registers all the default resources and optionally any provided overrides (or additional, non-default resources). The optional overrides argument is useful if you need to override a resource in a test.
Types ¶
type FailureHandler ¶
type FailureHandler func(ctx context.Context, errDiag *tfprotov6.Diagnostic, providerConfig tftypes.Value)
FailureHandler A function that can be used to handle state plan/apply failures and enhance the error diagnostic.
func GetApplicationLogsFailureHandler ¶
func GetApplicationLogsFailureHandler(et *embeddedTransportV1, appNames []string) FailureHandler
GetApplicationLogsFailureHandler Creates a failure handler that fetches application logs, downloads them to a file and updates the error diagnostic with a list of logs that were retrieved and where they were saved.
func TransportDebugFailureHandler ¶
func TransportDebugFailureHandler(et *embeddedTransportV1) FailureHandler
TransportDebugFailureHandler adds the transport configuration to the provided diagnostic.
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
Provider implements the internal server.Provider interface.
func (*Provider) Configure ¶
func (p *Provider) Configure(ctx context.Context, req *tfprotov6.ConfigureProviderRequest) (*tfprotov6.ConfigureProviderResponse, error)
Configure is called to pass the user-specified provider configuration to the provider.
func (*Provider) MetaSchema ¶
MetaSchema is the schema for the providers metadata.
func (*Provider) Stop ¶
func (p *Provider) Stop(ctx context.Context, req *tfprotov6.StopProviderRequest) (*tfprotov6.StopProviderResponse, error)
Stop is called when Terraform would like providers to shut down as quickly as possible, and usually represents an interrupt.
func (*Provider) Validate ¶
func (p *Provider) Validate(ctx context.Context, req *tfprotov6.ValidateProviderConfigRequest) (*tfprotov6.ValidateProviderConfigResponse, error)
Validate is called to give a provider a chance to validate the configuration.
type StateWithTransport ¶
type Transports ¶
type Transports map[it.TransportType]transportState
Source Files ¶
- datasource_artifactory_item.go
- datasource_environment.go
- datasource_kubernetes_pods.go
- doc.go
- embedded_transport.go
- embedded_transport_k8s.go
- embedded_transport_nomad.go
- embedded_transport_ssh.go
- errors.go
- exec_config.go
- failure_handlers.go
- interfaces.go
- ip_resolver.go
- provider.go
- resource_boundary_init.go
- resource_boundary_start.go
- resource_bundle_install.go
- resource_consul_start.go
- resource_file.go
- resource_host_info.go
- resource_local_exec.go
- resource_local_kind_cluster.go
- resource_local_kind_load_image.go
- resource_remote_exec.go
- resource_user.go
- resource_vault_init.go
- resource_vault_start.go
- resource_vault_unseal.go
- server.go
- tftypes.go
- transport_resource_util.go
- vault_config_block.go
- vault_config_seals.go
- vault_config_storage.go