provider

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2023 License: Apache-2.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CockroachAPIKey string = "COCKROACH_API_KEY"
	APIServerURLKey string = "COCKROACH_SERVER"
	UserAgent       string = "terraform-provider-cockroach"
)

Variables

View Source
var NewService = client.NewService

NewService overrides the client method for testing.

Functions

func HookGlobal added in v0.3.0

func HookGlobal[T any](ptr *T, val T) func()

HookGlobal sets `*ptr = val` and returns a closure for restoring `*ptr` to its original value. A runtime panic will occur if `val` is not assignable to `*ptr`.

func New

func New(version string) func() tf_provider.Provider

func NewAllowlistResource added in v0.4.0

func NewAllowlistResource() resource.Resource

func NewCMEKResource added in v0.4.0

func NewCMEKResource() resource.Resource

func NewClusterCertDataSource added in v0.4.1

func NewClusterCertDataSource() datasource.DataSource

func NewClusterDataSource added in v0.4.0

func NewClusterDataSource() datasource.DataSource

func NewClusterResource added in v0.4.0

func NewClusterResource() resource.Resource

func NewConnectionStringDataSource added in v0.4.1

func NewConnectionStringDataSource() datasource.DataSource

func NewPrivateEndpointConnectionResource added in v0.4.0

func NewPrivateEndpointConnectionResource() resource.Resource

func NewPrivateEndpointServicesResource added in v0.4.0

func NewPrivateEndpointServicesResource() resource.Resource

func NewSQLUserResource added in v0.4.0

func NewSQLUserResource() resource.Resource

Types

type APIErrorMessage

type APIErrorMessage struct {
	Code     int
	Message  string
	HttpCode int
}

func (*APIErrorMessage) String

func (e *APIErrorMessage) String() string

type AllowlistEntry

type AllowlistEntry struct {
	ClusterId types.String `tfsdk:"cluster_id"`
	CidrIp    types.String `tfsdk:"cidr_ip"`
	CidrMask  types.Int64  `tfsdk:"cidr_mask"`
	Ui        types.Bool   `tfsdk:"ui"`
	Sql       types.Bool   `tfsdk:"sql"`
	Name      types.String `tfsdk:"name"`
	ID        types.String `tfsdk:"id"`
}

type CMEKKey added in v0.4.0

type CMEKKey struct {
	Status        types.String `tfsdk:"status"`
	UserMessage   types.String `tfsdk:"user_message"`
	Type          types.String `tfsdk:"type"`
	URI           types.String `tfsdk:"uri"`
	AuthPrincipal types.String `tfsdk:"auth_principal"`
	CreatedAt     types.String `tfsdk:"created_at"`
	UpdatedAt     types.String `tfsdk:"updated_at"`
}

type CMEKRegion added in v0.4.0

type CMEKRegion struct {
	Region types.String `tfsdk:"region"`
	Status types.String `tfsdk:"status"`
	Key    CMEKKey      `tfsdk:"key"`
}

type ClusterCMEK added in v0.4.0

type ClusterCMEK struct {
	ID                types.String `tfsdk:"id"`
	Status            types.String `tfsdk:"status"`
	Regions           []CMEKRegion `tfsdk:"regions"`
	AdditionalRegions []Region     `tfsdk:"additional_regions"`
}

type ClusterCert added in v0.4.1

type ClusterCert struct {
	ID   types.String `tfsdk:"id"`
	Cert types.String `tfsdk:"cert"`
}

type CockroachCluster

type CockroachCluster struct {
	ID               types.String             `tfsdk:"id"`
	Name             types.String             `tfsdk:"name"`
	CloudProvider    types.String             `tfsdk:"cloud_provider"`
	AccountId        types.String             `tfsdk:"account_id"`
	DedicatedConfig  *DedicatedClusterConfig  `tfsdk:"dedicated"`
	ServerlessConfig *ServerlessClusterConfig `tfsdk:"serverless"`
	Regions          []Region                 `tfsdk:"regions"`
	CockroachVersion types.String             `tfsdk:"cockroach_version"`
	Plan             types.String             `tfsdk:"plan"`
	State            types.String             `tfsdk:"state"`
	CreatorId        types.String             `tfsdk:"creator_id"`
	OperationStatus  types.String             `tfsdk:"operation_status"`
}

type ConnectionString added in v0.4.1

type ConnectionString struct {
	ID               types.String `tfsdk:"id"`
	OS               types.String `tfsdk:"os"`
	Database         types.String `tfsdk:"database"`
	SqlUser          types.String `tfsdk:"sql_user"`
	Password         types.String `tfsdk:"password"`
	ConnectionString types.String `tfsdk:"connection_string"`
	ConnectionParams types.Map    `tfsdk:"connection_params"`
}

type DedicatedClusterConfig added in v0.2.0

type DedicatedClusterConfig struct {
	MachineType              types.String  `tfsdk:"machine_type"`
	NumVirtualCpus           types.Int64   `tfsdk:"num_virtual_cpus"`
	StorageGib               types.Int64   `tfsdk:"storage_gib"`
	MemoryGib                types.Float64 `tfsdk:"memory_gib"`
	DiskIops                 types.Int64   `tfsdk:"disk_iops"`
	PrivateNetworkVisibility types.Bool    `tfsdk:"private_network_visibility"`
}

type PrivateEndpointConnection added in v0.3.0

type PrivateEndpointConnection struct {
	ID            types.String `tfsdk:"id"`
	RegionName    types.String `tfsdk:"region_name"`
	CloudProvider types.String `tfsdk:"cloud_provider"`
	EndpointID    types.String `tfsdk:"endpoint_id"`
	ServiceID     types.String `tfsdk:"service_id"`
	ClusterID     types.String `tfsdk:"cluster_id"`
}

type PrivateEndpointService added in v0.3.0

type PrivateEndpointService struct {
	RegionName    types.String                `tfsdk:"region_name"`
	CloudProvider types.String                `tfsdk:"cloud_provider"`
	Status        types.String                `tfsdk:"status"`
	Aws           PrivateLinkServiceAWSDetail `tfsdk:"aws"`
}

type PrivateEndpointServices added in v0.3.0

type PrivateEndpointServices struct {
	ClusterID types.String             `tfsdk:"cluster_id"`
	Services  []PrivateEndpointService `tfsdk:"services"`
	ID        types.String             `tfsdk:"id"`
}

type PrivateLinkServiceAWSDetail added in v0.3.0

type PrivateLinkServiceAWSDetail struct {
	ServiceName         types.String   `tfsdk:"service_name"`
	ServiceId           types.String   `tfsdk:"service_id"`
	AvailabilityZoneIds []types.String `tfsdk:"availability_zone_ids"`
}

type Region

type Region struct {
	Name      types.String `tfsdk:"name"`
	SqlDns    types.String `tfsdk:"sql_dns"`
	UiDns     types.String `tfsdk:"ui_dns"`
	NodeCount types.Int64  `tfsdk:"node_count"`
}

type SQLUser

type SQLUser struct {
	ClusterId types.String `tfsdk:"cluster_id"`
	Name      types.String `tfsdk:"name"`
	Password  types.String `tfsdk:"password"`
	ID        types.String `tfsdk:"id"`
}

type ServerlessClusterConfig

type ServerlessClusterConfig struct {
	SpendLimit types.Int64  `tfsdk:"spend_limit"`
	RoutingId  types.String `tfsdk:"routing_id"`
}

Jump to

Keyboard shortcuts

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