This commit is contained in:
asteam
2024-12-04 13:18:58 +03:00
parent 003e4d656e
commit 76ea459b3d
417 changed files with 30051 additions and 975 deletions

View File

@@ -89,25 +89,48 @@ type RecordResourcesModel struct {
}
type VNFInterfaceModel struct {
ConnID types.Int64 `tfsdk:"conn_id"`
ConnType types.String `tfsdk:"conn_type"`
DefGW types.String `tfsdk:"def_gw"`
Enabled types.Bool `tfsdk:"enabled"`
FLIPGroupID types.Int64 `tfsdk:"flipgroup_id"`
BusNumber types.Int64 `tfsdk:"bus_number"`
ConnID types.Int64 `tfsdk:"conn_id"`
ConnType types.String `tfsdk:"conn_type"`
DefGW types.String `tfsdk:"def_gw"`
Enabled types.Bool `tfsdk:"enabled"`
FLIPGroupID types.Int64 `tfsdk:"flipgroup_id"`
GUID types.String `tfsdk:"guid"`
IPAddress types.String `tfsdk:"ip_address"`
Libvirtsettings types.Object `tfsdk:"libvirt_settings"`
ListenSSH types.Bool `tfsdk:"listen_ssh"`
MAC types.String `tfsdk:"mac"`
MTU types.Int64 `tfsdk:"mtu"`
Name types.String `tfsdk:"name"`
NetID types.Int64 `tfsdk:"net_id"`
NetMask types.Int64 `tfsdk:"net_mask"`
NetType types.String `tfsdk:"net_type"`
NodeID types.Int64 `tfsdk:"node_id"`
PCISlot types.Int64 `tfsdk:"pci_slot"`
QOS types.Object `tfsdk:"qos"`
Target types.String `tfsdk:"target"`
Type types.String `tfsdk:"type"`
VNFs types.List `tfsdk:"vnfs"`
}
type LibvirtSettingsModel struct {
TXMode types.String `tfsdk:"txmode"`
IOEventFD types.String `tfsdk:"ioeventfd"`
EventIDx types.String `tfsdk:"event_idx"`
Queues types.Int64 `tfsdk:"queues"`
RXQueueSize types.Int64 `tfsdk:"rx_queue_size"`
TXQueueSize types.Int64 `tfsdk:"tx_queue_size"`
GUID types.String `tfsdk:"guid"`
IPAddress types.String `tfsdk:"ip_address"`
ListenSSH types.Bool `tfsdk:"listen_ssh"`
MAC types.String `tfsdk:"mac"`
Name types.String `tfsdk:"name"`
NetID types.Int64 `tfsdk:"net_id"`
NetMask types.Int64 `tfsdk:"net_mask"`
NetType types.String `tfsdk:"net_type"`
NodeID types.Int64 `tfsdk:"node_id"`
PCISlot types.Int64 `tfsdk:"pci_slot"`
QOS types.Object `tfsdk:"qos"`
Target types.String `tfsdk:"target"`
Type types.String `tfsdk:"type"`
VNFs types.List `tfsdk:"vnfs"`
}
var LibvirtSettings = map[string]attr.Type{
"txmode": types.StringType,
"ioeventfd": types.StringType,
"event_idx": types.StringType,
"queues": types.Int64Type,
"rx_queue_size": types.Int64Type,
"tx_queue_size": types.Int64Type,
"guid": types.StringType,
}
type QOSModel struct {
@@ -278,25 +301,28 @@ var ItemVNFDev = map[string]attr.Type{
}
var ItemInterface = map[string]attr.Type{
"conn_id": types.Int64Type,
"conn_type": types.StringType,
"def_gw": types.StringType,
"enabled": types.BoolType,
"flipgroup_id": types.Int64Type,
"guid": types.StringType,
"ip_address": types.StringType,
"listen_ssh": types.BoolType,
"mac": types.StringType,
"name": types.StringType,
"net_id": types.Int64Type,
"net_mask": types.Int64Type,
"net_type": types.StringType,
"node_id": types.Int64Type,
"pci_slot": types.Int64Type,
"qos": types.ObjectType{AttrTypes: ItemQOS},
"target": types.StringType,
"type": types.StringType,
"vnfs": types.ListType{ElemType: types.Int64Type},
"bus_number": types.Int64Type,
"conn_id": types.Int64Type,
"conn_type": types.StringType,
"def_gw": types.StringType,
"enabled": types.BoolType,
"flipgroup_id": types.Int64Type,
"guid": types.StringType,
"ip_address": types.StringType,
"libvirt_settings": types.ObjectType{AttrTypes: LibvirtSettings},
"listen_ssh": types.BoolType,
"mac": types.StringType,
"mtu": types.Int64Type,
"name": types.StringType,
"net_id": types.Int64Type,
"net_mask": types.Int64Type,
"net_type": types.StringType,
"node_id": types.Int64Type,
"pci_slot": types.Int64Type,
"qos": types.ObjectType{AttrTypes: ItemQOS},
"target": types.StringType,
"type": types.StringType,
"vnfs": types.ListType{ElemType: types.Int64Type},
}
var ItemQOS = map[string]attr.Type{

View File

@@ -12,6 +12,7 @@ type DataSourceVINSListModel struct {
AccountID types.Int64 `tfsdk:"account_id"`
RGID types.Int64 `tfsdk:"rg_id"`
ExtIP types.String `tfsdk:"ext_ip"`
VNFDevID types.Int64 `tfsdk:"vnf_dev_id"`
IncludeDeleted types.Bool `tfsdk:"include_deleted"`
Page types.Int64 `tfsdk:"page"`
SortBy types.String `tfsdk:"sort_by"`