Documentation
¶
Index ¶
- Constants
- func New(version string) func() provider.Provider
- func NewBuildingBlockDataSource() datasource.DataSource
- func NewBuildingBlockResource() resource.Resource
- func NewProjectDataSource() datasource.DataSource
- func NewProjectResource() resource.Resource
- func NewTenantDataSource() datasource.DataSource
- func NewTenantResource() resource.Resource
- type BuildingBlockResource
- func (r *BuildingBlockResource) Configure(ctx context.Context, req resource.ConfigureRequest, ...)
- func (r *BuildingBlockResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
- func (r *BuildingBlockResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
- func (r *BuildingBlockResource) ImportState(ctx context.Context, req resource.ImportStateRequest, ...)
- func (r *BuildingBlockResource) Metadata(ctx context.Context, req resource.MetadataRequest, ...)
- func (r *BuildingBlockResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
- func (r *BuildingBlockResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse)
- func (r *BuildingBlockResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
- type BuildingBlockResourceModel
- type MeshBuildingBlock
- type MeshBuildingBlockIO
- type MeshBuildingBlockMetadata
- type MeshBuildingBlockParent
- type MeshBuildingBlockSpec
- type MeshBuildingBlockStatus
- type MeshProject
- type MeshProjectCreate
- type MeshProjectCreateMetadata
- type MeshProjectMetadata
- type MeshProjectSpec
- type MeshStackProvider
- func (p *MeshStackProvider) Configure(ctx context.Context, req provider.ConfigureRequest, ...)
- func (p *MeshStackProvider) DataSources(ctx context.Context) []func() datasource.DataSource
- func (p *MeshStackProvider) Metadata(ctx context.Context, req provider.MetadataRequest, ...)
- func (p *MeshStackProvider) Resources(ctx context.Context) []func() resource.Resource
- func (p *MeshStackProvider) Schema(ctx context.Context, req provider.SchemaRequest, resp *provider.SchemaResponse)
- type MeshStackProviderClient
- func (c *MeshStackProviderClient) CreateProject(project *MeshProjectCreate) (*MeshProject, error)
- func (c *MeshStackProviderClient) CreateTenant(tenant *MeshTenantCreate) (*MeshTenant, error)
- func (c *MeshStackProviderClient) DeleteProject(workspace string, name string) error
- func (c *MeshStackProviderClient) DeleteTenant(workspace string, project string, platform string) error
- func (c *MeshStackProviderClient) ReadBuildingBlock(uuid string) (*MeshBuildingBlock, error)
- func (c *MeshStackProviderClient) ReadProject(workspace string, name string) (*MeshProject, error)
- func (c *MeshStackProviderClient) ReadTenant(workspace string, project string, platform string) (*MeshTenant, error)
- func (c *MeshStackProviderClient) UpdateProject(project *MeshProjectCreate) (*MeshProject, error)
- type MeshStackProviderModel
- type MeshTenant
- type MeshTenantCreate
- type MeshTenantCreateMetadata
- type MeshTenantCreateSpec
- type MeshTenantMetadata
- type MeshTenantQuota
- type MeshTenantSpec
Constants ¶
View Source
const ( ERROR_GENERIC_CLIENT_ERROR = "client error" ERROR_GENERIC_API_ERROR = "api error" ERROR_AUTHENTICATION_FAILURE = "Not authorized. Check api key and secret." ERROR_ENDPOINT_LOOKUP = "Could not fetch endpoints for meshStack." CONTENT_TYPE_PROJECT = "application/vnd.meshcloud.api.meshproject.v2.hal+json" CONTENT_TYPE_TENANT = "application/vnd.meshcloud.api.meshtenant.v3.hal+json" )
Variables ¶
This section is empty.
Functions ¶
func NewBuildingBlockDataSource ¶
func NewBuildingBlockDataSource() datasource.DataSource
func NewProjectDataSource ¶
func NewProjectDataSource() datasource.DataSource
func NewProjectResource ¶
NewProjectResource is a helper function to simplify the provider implementation.
func NewTenantDataSource ¶ added in v0.2.0
func NewTenantDataSource() datasource.DataSource
func NewTenantResource ¶ added in v0.2.0
Types ¶
type BuildingBlockResource ¶
type BuildingBlockResource struct {
// contains filtered or unexported fields
}
func (*BuildingBlockResource) Configure ¶
func (r *BuildingBlockResource) Configure(ctx context.Context, req resource.ConfigureRequest, resp *resource.ConfigureResponse)
func (*BuildingBlockResource) Create ¶
func (r *BuildingBlockResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
func (*BuildingBlockResource) Delete ¶
func (r *BuildingBlockResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
func (*BuildingBlockResource) ImportState ¶
func (r *BuildingBlockResource) ImportState(ctx context.Context, req resource.ImportStateRequest, resp *resource.ImportStateResponse)
func (*BuildingBlockResource) Metadata ¶
func (r *BuildingBlockResource) Metadata(ctx context.Context, req resource.MetadataRequest, resp *resource.MetadataResponse)
func (*BuildingBlockResource) Read ¶
func (r *BuildingBlockResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
func (*BuildingBlockResource) Schema ¶
func (r *BuildingBlockResource) Schema(ctx context.Context, req resource.SchemaRequest, resp *resource.SchemaResponse)
func (*BuildingBlockResource) Update ¶
func (r *BuildingBlockResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
type BuildingBlockResourceModel ¶
type BuildingBlockResourceModel struct {
Uuid types.String `tfsdk:"uuid"`
DefinitionUUid types.String `tfsdk:"definition_uuid"`
DefinitionVersion types.Int64 `tfsdk:"definition_version"`
TenantIdentifier types.String `tfsdk:"tenant_identifier"`
DisplayName types.String `tfsdk:"display_name"`
Inputs types.Map `tfsdk:"inputs"`
Parents types.Set `tfsdk:"parents"`
}
type MeshBuildingBlock ¶
type MeshBuildingBlock struct {
ApiVersion string `json:"apiVersion" tfsdk:"api_version"`
Kind string `json:"kind" tfsdk:"kind"`
Metadata MeshBuildingBlockMetadata `json:"metadata" tfsdk:"metadata"`
Spec MeshBuildingBlockSpec `json:"spec" tfsdk:"spec"`
Status MeshBuildingBlockStatus `json:"status" tfsdk:"status"`
}
type MeshBuildingBlockIO ¶
type MeshBuildingBlockMetadata ¶
type MeshBuildingBlockMetadata struct {
Uuid string `json:"uuid" tfsdk:"uuid"`
DefinitionUuid string `json:"definitionUuid" tfsdk:"definition_uuid"`
DefinitionVersion int64 `json:"definitionVersion" tfsdk:"definition_version"`
TenantIdentifier string `json:"tenantIdentifier" tfsdk:"tenant_identifier"`
ForcePurge bool `json:"forcePurge" tfsdk:"force_purge"`
CreatedOn string `json:"createdOn" tfsdk:"created_on"`
MarkedForDeletionOn *string `json:"markedForDeletionOn" tfsdk:"marked_for_deletion_on"`
MarkedForDeletionBy *string `json:"markedForDeletionBy" tfsdk:"marked_for_deletion_by"`
}
type MeshBuildingBlockParent ¶
type MeshBuildingBlockSpec ¶
type MeshBuildingBlockSpec struct {
DisplayName string `json:"displayName" tfsdk:"display_name"`
Inputs []MeshBuildingBlockIO `json:"inputs" tfsdk:"inputs"`
ParentBuildingBlocks []MeshBuildingBlockParent `json:"parentBuildingBlocks" tfsdk:"parent_building_blocks"`
}
type MeshBuildingBlockStatus ¶
type MeshBuildingBlockStatus struct {
Status string `json:"status" tfsdk:"status"`
Outputs []MeshBuildingBlockIO `json:"outputs" tfsdk:"outputs"`
}
type MeshProject ¶
type MeshProject struct {
ApiVersion string `json:"apiVersion" tfsdk:"api_version"`
Kind string `json:"kind" tfsdk:"kind"`
Metadata MeshProjectMetadata `json:"metadata" tfsdk:"metadata"`
Spec MeshProjectSpec `json:"spec" tfsdk:"spec"`
}
type MeshProjectCreate ¶
type MeshProjectCreate struct {
Metadata MeshProjectCreateMetadata `json:"metadata" tfsdk:"metadata"`
Spec MeshProjectSpec `json:"spec" tfsdk:"spec"`
}
type MeshProjectMetadata ¶
type MeshProjectSpec ¶
type MeshProjectSpec struct {
DisplayName string `json:"displayName" tfsdk:"display_name"`
Tags map[string][]string `json:"tags" tfsdk:"tags"`
PaymentMethodIdentifier *string `json:"paymentMethodIdentifier" tfsdk:"payment_method_identifier"`
SubstitutePaymentMethodIdentifier *string `json:"substitutePaymentMethodIdentifier" tfsdk:"substitute_payment_method_identifier"`
}
type MeshStackProvider ¶
type MeshStackProvider struct {
// contains filtered or unexported fields
}
func (*MeshStackProvider) Configure ¶
func (p *MeshStackProvider) Configure(ctx context.Context, req provider.ConfigureRequest, resp *provider.ConfigureResponse)
func (*MeshStackProvider) DataSources ¶
func (p *MeshStackProvider) DataSources(ctx context.Context) []func() datasource.DataSource
func (*MeshStackProvider) Metadata ¶
func (p *MeshStackProvider) Metadata(ctx context.Context, req provider.MetadataRequest, resp *provider.MetadataResponse)
func (*MeshStackProvider) Resources ¶
func (p *MeshStackProvider) Resources(ctx context.Context) []func() resource.Resource
func (*MeshStackProvider) Schema ¶
func (p *MeshStackProvider) Schema(ctx context.Context, req provider.SchemaRequest, resp *provider.SchemaResponse)
type MeshStackProviderClient ¶
type MeshStackProviderClient struct {
// contains filtered or unexported fields
}
TODO this will be an abstraction that does the login call, get a token and then use this token in the Auth header.
func (*MeshStackProviderClient) CreateProject ¶
func (c *MeshStackProviderClient) CreateProject(project *MeshProjectCreate) (*MeshProject, error)
func (*MeshStackProviderClient) CreateTenant ¶ added in v0.2.0
func (c *MeshStackProviderClient) CreateTenant(tenant *MeshTenantCreate) (*MeshTenant, error)
func (*MeshStackProviderClient) DeleteProject ¶
func (c *MeshStackProviderClient) DeleteProject(workspace string, name string) error
func (*MeshStackProviderClient) DeleteTenant ¶ added in v0.2.0
func (c *MeshStackProviderClient) DeleteTenant(workspace string, project string, platform string) error
func (*MeshStackProviderClient) ReadBuildingBlock ¶
func (c *MeshStackProviderClient) ReadBuildingBlock(uuid string) (*MeshBuildingBlock, error)
func (*MeshStackProviderClient) ReadProject ¶
func (c *MeshStackProviderClient) ReadProject(workspace string, name string) (*MeshProject, error)
func (*MeshStackProviderClient) ReadTenant ¶ added in v0.2.0
func (c *MeshStackProviderClient) ReadTenant(workspace string, project string, platform string) (*MeshTenant, error)
func (*MeshStackProviderClient) UpdateProject ¶
func (c *MeshStackProviderClient) UpdateProject(project *MeshProjectCreate) (*MeshProject, error)
type MeshStackProviderModel ¶
type MeshTenant ¶ added in v0.2.0
type MeshTenant struct {
ApiVersion string `json:"apiVersion" tfsdk:"api_version"`
Kind string `json:"kind" tfsdk:"kind"`
Metadata MeshTenantMetadata `json:"metadata" tfsdk:"metadata"`
Spec MeshTenantSpec `json:"spec" tfsdk:"spec"`
}
type MeshTenantCreate ¶ added in v0.2.0
type MeshTenantCreate struct {
Metadata MeshTenantCreateMetadata `json:"metadata" tfsdk:"metadata"`
Spec MeshTenantCreateSpec `json:"spec" tfsdk:"spec"`
}
type MeshTenantCreateMetadata ¶ added in v0.2.0
type MeshTenantCreateSpec ¶ added in v0.2.0
type MeshTenantCreateSpec struct {
LocalId *string `json:"localId" tfsdk:"local_id"`
LandingZoneIdentifier *string `json:"landingZoneIdentifier" tfsdk:"landing_zone_identifier"`
Quotas *[]MeshTenantQuota `json:"quotas" tfsdk:"quotas"`
}
type MeshTenantMetadata ¶ added in v0.2.0
type MeshTenantMetadata struct {
OwnedByProject string `json:"ownedByProject" tfsdk:"owned_by_project"`
OwnedByWorkspace string `json:"ownedByWorkspace" tfsdk:"owned_by_workspace"`
PlatformIdentifier string `json:"platformIdentifier" tfsdk:"platform_identifier"`
AssignedTags map[string][]string `json:"assignedTags" tfsdk:"assigned_tags"`
DeletedOn *string `json:"deletedOn" tfsdk:"deleted_on"`
}
type MeshTenantQuota ¶ added in v0.2.0
type MeshTenantSpec ¶ added in v0.2.0
type MeshTenantSpec struct {
LocalId *string `json:"localId" tfsdk:"local_id"`
LandingZoneIdentifier string `json:"landingZoneIdentifier" tfsdk:"landing_zone_identifier"`
Quotas []MeshTenantQuota `json:"quotas" tfsdk:"quotas"`
}
Click to show internal directories.
Click to hide internal directories.