Documentation ¶
Index ¶
- func New(version string) func() provider.Provider
- func NewWorkspaceResource() resource.Resource
- func NewWorkspacesDataSource() datasource.DataSource
- type Structurizr
- func (p *Structurizr) Configure(ctx context.Context, req provider.ConfigureRequest, ...)
- func (p *Structurizr) DataSources(_ context.Context) []func() datasource.DataSource
- func (p *Structurizr) Metadata(_ context.Context, _ provider.MetadataRequest, resp *provider.MetadataResponse)
- func (p *Structurizr) Resources(_ context.Context) []func() resource.Resource
- func (p *Structurizr) Schema(_ context.Context, _ provider.SchemaRequest, resp *provider.SchemaResponse)
- type StructurizrProviderModel
- type WorkspaceModel
- type WorkspaceResourceModel
- type WorkspacesModel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewWorkspaceResource ¶
NewWorkspaceResource is a helper function to simplify the provider implementation.
func NewWorkspacesDataSource ¶
func NewWorkspacesDataSource() datasource.DataSource
NewWorkspacesDataSource is a helper function to simplify the provider implementation.
Types ¶
type Structurizr ¶
type Structurizr struct {
// contains filtered or unexported fields
}
Structurizr defines the provider implementation.
func (*Structurizr) Configure ¶
func (p *Structurizr) Configure(ctx context.Context, req provider.ConfigureRequest, resp *provider.ConfigureResponse)
func (*Structurizr) DataSources ¶
func (p *Structurizr) DataSources(_ context.Context) []func() datasource.DataSource
DataSources registers all available data sources that can be used to retrieve data
func (*Structurizr) Metadata ¶
func (p *Structurizr) Metadata(_ context.Context, _ provider.MetadataRequest, resp *provider.MetadataResponse)
Metadata returns the provider type name and version. It can be used to register other type of information
func (*Structurizr) Resources ¶
func (p *Structurizr) Resources(_ context.Context) []func() resource.Resource
Resources registers all available resource to be managed by Terraform
func (*Structurizr) Schema ¶
func (p *Structurizr) Schema(_ context.Context, _ provider.SchemaRequest, resp *provider.SchemaResponse)
Schema defines the schema for the resource
type StructurizrProviderModel ¶
type StructurizrProviderModel struct { Host types.String `tfsdk:"host"` AdminAPIKey types.String `tfsdk:"admin_api_key"` TLSInsecure types.Bool `tfsdk:"tls_insecure"` }
StructurizrProviderModel describes the provider data model.
type WorkspaceModel ¶
type WorkspaceModel struct { ID types.Int64 `tfsdk:"id"` Name types.String `tfsdk:"name"` Description types.String `tfsdk:"description"` APIKey types.String `tfsdk:"api_key"` APISecret types.String `tfsdk:"api_secret"` PublicURL types.String `tfsdk:"public_url"` PrivateURL types.String `tfsdk:"private_url"` }
WorkspaceModel represents a workspace configured in the structurizr
type WorkspaceResourceModel ¶
type WorkspaceResourceModel struct { ID types.Int64 `tfsdk:"id"` Name types.String `tfsdk:"name"` Description types.String `tfsdk:"description"` APIKey types.String `tfsdk:"api_key"` APISecret types.String `tfsdk:"api_secret"` PublicURL types.String `tfsdk:"public_url"` PrivateURL types.String `tfsdk:"private_url"` Source types.String `tfsdk:"source"` SourceChecksum types.String `tfsdk:"source_checksum"` SourcePassphrase types.String `tfsdk:"source_passphrase"` LastUpdated types.String `tfsdk:"last_updated"` }
WorkspaceResourceModel represents a workspace in the structurizr
type WorkspacesModel ¶
type WorkspacesModel struct {
Workspaces []WorkspaceModel `tfsdk:"workspaces"`
}
WorkspacesModel is the response body for any CRU methods