Documentation ¶
Index ¶
- func DataSources() []func() datasource.DataSource
- func NewGuestDataSource() datasource.DataSource
- func NewGuestListDataSource() datasource.DataSource
- func NewGuestResource() resource.Resource
- func NewImageResource() resource.Resource
- func Resources() []func() resource.Resource
- type GuestDataSource
- func (d *GuestDataSource) Configure(ctx context.Context, req datasource.ConfigureRequest, ...)
- func (d *GuestDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, ...)
- func (d *GuestDataSource) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse)
- func (d *GuestDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, ...)
- type GuestDataSourceModel
- type GuestIsoModel
- type GuestListDataSource
- func (d *GuestListDataSource) Configure(ctx context.Context, req datasource.ConfigureRequest, ...)
- func (d *GuestListDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, ...)
- func (d *GuestListDataSource) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse)
- func (d *GuestListDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, ...)
- type GuestListDataSourceModel
- type GuestResource
- func (f *GuestResource) Configure(ctx context.Context, req resource.ConfigureRequest, ...)
- func (f *GuestResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
- func (f *GuestResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
- func (f *GuestResource) ImportState(ctx context.Context, req resource.ImportStateRequest, ...)
- func (f *GuestResource) Metadata(_ context.Context, req resource.MetadataRequest, ...)
- func (f *GuestResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
- func (f *GuestResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse)
- func (f *GuestResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
- func (f *GuestResource) ValidateConfig(ctx context.Context, req resource.ValidateConfigRequest, ...)
- type GuestResourceModel
- type ImageResource
- func (f *ImageResource) Configure(ctx context.Context, req resource.ConfigureRequest, ...)
- func (f *ImageResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
- func (f *ImageResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
- func (f *ImageResource) Metadata(_ context.Context, req resource.MetadataRequest, ...)
- func (f *ImageResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
- func (f *ImageResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse)
- func (f *ImageResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
- type ImageResourceModel
- type VDiskDataModel
- type VDiskModel
- type VNicDataModel
- type VNicModel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DataSources ¶
func DataSources() []func() datasource.DataSource
func NewGuestDataSource ¶
func NewGuestDataSource() datasource.DataSource
func NewGuestListDataSource ¶
func NewGuestListDataSource() datasource.DataSource
func NewGuestResource ¶
func NewImageResource ¶
Types ¶
type GuestDataSource ¶
type GuestDataSource struct {
// contains filtered or unexported fields
}
func (*GuestDataSource) Configure ¶
func (d *GuestDataSource) Configure(ctx context.Context, req datasource.ConfigureRequest, resp *datasource.ConfigureResponse)
func (*GuestDataSource) Metadata ¶
func (d *GuestDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse)
func (*GuestDataSource) Read ¶
func (d *GuestDataSource) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse)
func (*GuestDataSource) Schema ¶
func (d *GuestDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse)
type GuestDataSourceModel ¶
type GuestDataSourceModel struct { ID types.String `tfsdk:"id"` Name types.String `tfsdk:"name"` Description types.String `tfsdk:"description"` Status types.String `tfsdk:"status"` StorageID types.String `tfsdk:"storage_id"` StorageName types.String `tfsdk:"storage_name"` Autorun types.Int64 `tfsdk:"autorun"` VcpuNum types.Int64 `tfsdk:"vcpu_num"` VramSize types.Int64 `tfsdk:"vram_size"` Disks types.Set `tfsdk:"disks"` Networks types.Set `tfsdk:"networks"` }
func (GuestDataSourceModel) AttrType ¶
func (m GuestDataSourceModel) AttrType() map[string]attr.Type
func (*GuestDataSourceModel) FromGuest ¶
func (m *GuestDataSourceModel) FromGuest(v *virtualization.Guest) error
func (GuestDataSourceModel) ModelType ¶
func (m GuestDataSourceModel) ModelType() attr.Type
func (GuestDataSourceModel) Value ¶
func (m GuestDataSourceModel) Value() attr.Value
type GuestIsoModel ¶
type GuestListDataSource ¶
type GuestListDataSource struct {
// contains filtered or unexported fields
}
func (*GuestListDataSource) Configure ¶
func (d *GuestListDataSource) Configure(ctx context.Context, req datasource.ConfigureRequest, resp *datasource.ConfigureResponse)
func (*GuestListDataSource) Metadata ¶
func (d *GuestListDataSource) Metadata(ctx context.Context, req datasource.MetadataRequest, resp *datasource.MetadataResponse)
func (*GuestListDataSource) Read ¶
func (d *GuestListDataSource) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse)
func (*GuestListDataSource) Schema ¶
func (d *GuestListDataSource) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse)
type GuestResource ¶
type GuestResource struct {
// contains filtered or unexported fields
}
func (*GuestResource) Configure ¶
func (f *GuestResource) Configure(ctx context.Context, req resource.ConfigureRequest, resp *resource.ConfigureResponse)
func (*GuestResource) Create ¶
func (f *GuestResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
Create implements resource.Resource.
func (*GuestResource) Delete ¶
func (f *GuestResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
Delete implements resource.Resource.
func (*GuestResource) ImportState ¶
func (f *GuestResource) ImportState(ctx context.Context, req resource.ImportStateRequest, resp *resource.ImportStateResponse)
func (*GuestResource) Metadata ¶
func (f *GuestResource) Metadata(_ context.Context, req resource.MetadataRequest, resp *resource.MetadataResponse)
Metadata implements resource.Resource.
func (*GuestResource) Read ¶
func (f *GuestResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
Read implements resource.Resource.
func (*GuestResource) Schema ¶
func (f *GuestResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse)
Schema implements resource.Resource.
func (*GuestResource) Update ¶
func (f *GuestResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
Update implements resource.Resource.
func (*GuestResource) ValidateConfig ¶
func (f *GuestResource) ValidateConfig(ctx context.Context, req resource.ValidateConfigRequest, resp *resource.ValidateConfigResponse)
ValidateConfig.
type GuestResourceModel ¶
type GuestResourceModel struct { ID types.String `tfsdk:"id"` Name types.String `tfsdk:"name"` // Description types.String `tfsdk:"description"` // Status types.String `tfsdk:"status"` StorageID types.String `tfsdk:"storage_id"` StorageName types.String `tfsdk:"storage_name"` // AutoRun types.Int64 `tfsdk:"autorun"` VcpuNum types.Int64 `tfsdk:"vcpu_num"` VramSize types.Int64 `tfsdk:"vram_size"` Disks types.Set `tfsdk:"disk"` Networks types.Set `tfsdk:"network"` IsoImages types.Set `tfsdk:"iso"` Run types.Bool `tfsdk:"run"` }
GuestResourceModel describes the resource data model.
type ImageResource ¶
type ImageResource struct {
// contains filtered or unexported fields
}
func (*ImageResource) Configure ¶
func (f *ImageResource) Configure(ctx context.Context, req resource.ConfigureRequest, resp *resource.ConfigureResponse)
func (*ImageResource) Create ¶
func (f *ImageResource) Create(ctx context.Context, req resource.CreateRequest, resp *resource.CreateResponse)
Create implements resource.Resource.
func (*ImageResource) Delete ¶
func (f *ImageResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse)
Delete implements resource.Resource.
func (*ImageResource) Metadata ¶
func (f *ImageResource) Metadata(_ context.Context, req resource.MetadataRequest, resp *resource.MetadataResponse)
Metadata implements resource.Resource.
func (*ImageResource) Read ¶
func (f *ImageResource) Read(ctx context.Context, req resource.ReadRequest, resp *resource.ReadResponse)
Read implements resource.Resource.
func (*ImageResource) Schema ¶
func (f *ImageResource) Schema(_ context.Context, _ resource.SchemaRequest, resp *resource.SchemaResponse)
Schema implements resource.Resource.
func (*ImageResource) Update ¶
func (f *ImageResource) Update(ctx context.Context, req resource.UpdateRequest, resp *resource.UpdateResponse)
Update implements resource.Resource.
type ImageResourceModel ¶
type ImageResourceModel struct { ID types.String `tfsdk:"id"` Name types.String `tfsdk:"name"` Path types.String `tfsdk:"path"` AutoClean types.Bool `tfsdk:"auto_clean"` ImageType types.String `tfsdk:"image_type"` StorageID types.String `tfsdk:"storage_id"` StorageName types.String `tfsdk:"storage_name"` }
ImageResourceModel describes the resource data model.
type VDiskDataModel ¶
type VDiskDataModel struct { ID types.String `tfsdk:"id"` Size types.Int64 `tfsdk:"size"` Controller types.Int64 `tfsdk:"controller"` Unmap types.Bool `tfsdk:"unmap"` }
func (VDiskDataModel) ModelType ¶
func (m VDiskDataModel) ModelType() attr.Type
func (VDiskDataModel) Value ¶
func (m VDiskDataModel) Value() attr.Value
type VDiskModel ¶
type VDiskModel struct { // ID types.String `tfsdk:"id"` Size types.Int64 `tfsdk:"size"` // Controller types.Int64 `tfsdk:"controller"` // Unmap types.Bool `tfsdk:"unmap"` ImageID types.String `tfsdk:"image_id"` ImageName types.String `tfsdk:"image_name"` }
func (VDiskModel) ModelType ¶
func (m VDiskModel) ModelType() attr.Type
func (VDiskModel) Value ¶
func (m VDiskModel) Value() attr.Value
type VNicDataModel ¶
type VNicDataModel struct { ID types.String `tfsdk:"id"` Mac types.String `tfsdk:"mac"` Model types.Int64 `tfsdk:"model"` Name types.String `tfsdk:"name"` VNicID types.String `tfsdk:"vnic_id"` }
func (VNicDataModel) ModelType ¶
func (m VNicDataModel) ModelType() attr.Type
func (VNicDataModel) Value ¶
func (m VNicDataModel) Value() attr.Value
Source Files ¶
Click to show internal directories.
Click to hide internal directories.