provider

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

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

New is a helper function to simplify provider server and testing implementation.

func NewAuthorizationDataSource

func NewAuthorizationDataSource() datasource.DataSource

NewAuthorizationDataSource is a helper function to simplify the provider implementation.

func NewAuthorizationResource

func NewAuthorizationResource() resource.Resource

NewAuthorizationResource is a helper function to simplify the provider implementation.

func NewAuthorizationsDataSource

func NewAuthorizationsDataSource() datasource.DataSource

NewAuthorizationsDataSource is a helper function to simplify the provider implementation.

func NewBucketDataSource

func NewBucketDataSource() datasource.DataSource

NewBucketDataSource is a helper function to simplify the provider implementation.

func NewBucketResource

func NewBucketResource() resource.Resource

NewBucketResource is a helper function to simplify the provider implementation.

func NewBucketsDataSource

func NewBucketsDataSource() datasource.DataSource

NewBucketsDataSource is a helper function to simplify the provider implementation.

func NewOrganizationDataSource

func NewOrganizationDataSource() datasource.DataSource

NewOrganizationDataSource is a helper function to simplify the provider implementation.

func NewOrganizationResource

func NewOrganizationResource() resource.Resource

NewOrganizationResource is a helper function to simplify the provider implementation.

func NewOrganizationsDataSource

func NewOrganizationsDataSource() datasource.DataSource

NewOrganizationsDataSource is a helper function to simplify the provider implementation.

Types

type AuthorizationDataSource

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

AuthorizationsDataSource is the data source implementation.

func (*AuthorizationDataSource) Configure

Configure adds the provider configured client to the data source.

func (*AuthorizationDataSource) Metadata

Metadata returns the data source type name.

func (*AuthorizationDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*AuthorizationDataSource) Schema

Schema defines the schema for the data source.

type AuthorizationModel

type AuthorizationModel struct {
	Id          types.String                   `tfsdk:"id"`
	Token       types.String                   `tfsdk:"token"`
	Status      types.String                   `tfsdk:"status"`
	Description types.String                   `tfsdk:"description"`
	OrgID       types.String                   `tfsdk:"org_id"`
	Org         types.String                   `tfsdk:"org"`
	UserId      types.String                   `tfsdk:"user_id"`
	User        types.String                   `tfsdk:"user"`
	CreatedAt   types.String                   `tfsdk:"created_at"`
	UpdatedAt   types.String                   `tfsdk:"updated_at"`
	Permissions []AuthorizationPermissionModel `tfsdk:"permissions"`
}

AuthorizationModel maps InfluxDB authorization schema data.

type AuthorizationPermissionModel

type AuthorizationPermissionModel struct {
	Action   types.String                         `tfsdk:"action"`
	Resource AuthorizationPermissionResourceModel `tfsdk:"resource"`
}

AuthorizationPermissionModel maps InfluxDB authorization permission schema data.

type AuthorizationPermissionResourceModel added in v1.1.0

type AuthorizationPermissionResourceModel struct {
	Id    types.String `tfsdk:"id"`
	Name  types.String `tfsdk:"name"`
	Org   types.String `tfsdk:"org"`
	OrgID types.String `tfsdk:"org_id"`
	Type  types.String `tfsdk:"type"`
}

AuthorizationPermissionResourceModel maps InfluxDB authorization permission resource schema data.

type AuthorizationResource

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

AuthorizationResource defines the resource implementation.

func (*AuthorizationResource) Configure

Configure adds the provider configured client to the resource.

func (*AuthorizationResource) Create

Create creates the resource and sets the initial Terraform state.

func (*AuthorizationResource) Delete

Delete deletes the resource and removes the Terraform state on success.

func (*AuthorizationResource) ImportState

func (*AuthorizationResource) Metadata

Metadata returns the resource type name.

func (*AuthorizationResource) Read

Read refreshes the Terraform state with the latest data.

func (*AuthorizationResource) Schema

Schema defines the schema for the resource.

func (*AuthorizationResource) Update

Update updates the resource and sets the updated Terraform state on success.

type AuthorizationsDataSource

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

AuthorizationsDataSource is the data source implementation.

func (*AuthorizationsDataSource) Configure

Configure adds the provider configured client to the data source.

func (*AuthorizationsDataSource) Metadata

Metadata returns the data source type name.

func (*AuthorizationsDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*AuthorizationsDataSource) Schema

Schema defines the schema for the data source.

type AuthorizationsDataSourceModel

type AuthorizationsDataSourceModel struct {
	Authorizations []AuthorizationModel `tfsdk:"authorizations"`
}

AuthorizationsDataSourceModel describes the data source data model.

type BucketDataSource

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

BucketsDataSource is the data source implementation.

func (*BucketDataSource) Configure

Configure adds the provider configured client to the data source.

func (*BucketDataSource) Metadata

Metadata returns the data source type name.

func (*BucketDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*BucketDataSource) Schema

Schema defines the schema for the data source.

type BucketModel

type BucketModel struct {
	Id              types.String `tfsdk:"id"`
	OrgID           types.String `tfsdk:"org_id"`
	Type            types.String `tfsdk:"type"`
	Description     types.String `tfsdk:"description"`
	Name            types.String `tfsdk:"name"`
	CreatedAt       types.String `tfsdk:"created_at"`
	UpdatedAt       types.String `tfsdk:"updated_at"`
	RetentionPeriod types.Int64  `tfsdk:"retention_period"` // buckets cannot have more than one retention rule at this time
}

BucketModel maps InfluxDB bucket schema data.

type BucketResource

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

BucketResource defines the resource implementation.

func (*BucketResource) Configure

Configure adds the provider configured client to the resource.

func (*BucketResource) Create

Create creates the resource and sets the initial Terraform state.

func (*BucketResource) Delete

Delete deletes the resource and removes the Terraform state on success.

func (*BucketResource) ImportState

func (*BucketResource) Metadata

Metadata returns the resource type name.

func (*BucketResource) Read

Read refreshes the Terraform state with the latest data.

func (*BucketResource) Schema

Schema defines the schema for the resource.

func (*BucketResource) Update

Update updates the resource and sets the updated Terraform state on success.

type BucketsDataSource

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

BucketsDataSource is the data source implementation.

func (*BucketsDataSource) Configure

Configure adds the provider configured client to the data source.

func (*BucketsDataSource) Metadata

Metadata returns the data source type name.

func (*BucketsDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*BucketsDataSource) Schema

Schema defines the schema for the data source.

type BucketsDataSourceModel

type BucketsDataSourceModel struct {
	Buckets []BucketModel `tfsdk:"buckets"`
}

BucketsDataSourceModel describes the data source data model.

type InfluxDBProvider

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

InfluxDBProvider defines the provider implementation.

func (*InfluxDBProvider) Configure

Configure prepares a InfluxDB API client for data sources and resources.

func (*InfluxDBProvider) DataSources

func (p *InfluxDBProvider) DataSources(ctx context.Context) []func() datasource.DataSource

DataSources defines the data sources implemented in the provider.

func (*InfluxDBProvider) Metadata

Metadata returns the provider type name.

func (*InfluxDBProvider) Resources

func (p *InfluxDBProvider) Resources(ctx context.Context) []func() resource.Resource

Resources defines the resources implemented in the provider.

func (*InfluxDBProvider) Schema

Schema defines the provider-level schema for configuration data.

type InfluxDBProviderModel

type InfluxDBProviderModel struct {
	URL   types.String `tfsdk:"url"`
	Token types.String `tfsdk:"token"`
}

InfluxDBProviderModel maps provider schema data to a Go type.

type OrganizationDataSource

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

OrganizationDataSource is the data source implementation.

func (*OrganizationDataSource) Configure

Configure adds the provider configured client to the data source.

func (*OrganizationDataSource) Metadata

Metadata returns the data source type name.

func (*OrganizationDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*OrganizationDataSource) Schema

Schema defines the schema for the data source.

type OrganizationModel

type OrganizationModel struct {
	Id          types.String `tfsdk:"id"`
	Name        types.String `tfsdk:"name"`
	Description types.String `tfsdk:"description"`
	CreatedAt   types.String `tfsdk:"created_at"`
	UpdatedAt   types.String `tfsdk:"updated_at"`
}

OrganizationModel maps InfluxDB organization schema data.

type OrganizationResource

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

OrganizationResource defines the resource implementation.

func (*OrganizationResource) Configure

Configure adds the provider configured client to the resource.

func (*OrganizationResource) Create

Create creates the resource and sets the initial Terraform state.

func (*OrganizationResource) Delete

Delete deletes the resource and removes the Terraform state on success.

func (*OrganizationResource) ImportState

func (*OrganizationResource) Metadata

Metadata returns the resource type name.

func (*OrganizationResource) Read

Read refreshes the Terraform state with the latest data.

func (*OrganizationResource) Schema

Schema defines the schema for the resource.

func (*OrganizationResource) Update

Update updates the resource and sets the updated Terraform state on success.

type OrganizationsDataSource

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

OrganizationsDataSource is the data source implementation.

func (*OrganizationsDataSource) Configure

Configure adds the provider configured client to the data source.

func (*OrganizationsDataSource) Metadata

Metadata returns the data source type name.

func (*OrganizationsDataSource) Read

Read refreshes the Terraform state with the latest data.

func (*OrganizationsDataSource) Schema

Schema defines the schema for the data source.

type OrganizationsDataSourceModel

type OrganizationsDataSourceModel struct {
	Organizations []OrganizationModel `tfsdk:"organizations"`
}

OrganizationsDataSourceModel describes the data source data model.

Jump to

Keyboard shortcuts

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