inst_req_data = {
"flavourId": "flavour_1",
"instantiationLevelId": "instantiationLevel_1",
- "vnfmId": "vnfm_1",
"extVirtualLinks": [
{
- "vlInstanceId": "1",
- "vim": {
- "vimInfoId": "1",
- "vimId": "1",
- "interfaceInfo": {
- "vimType": "vim",
- "apiVersion": "v2",
- "protocolType": "http"
- },
- "accessInfo": {
- "tenant": "tenant_vCPE",
- "username": "vCPE",
- "password": "vCPE_321"
- },
- "interfaceEndpoint": "http://10.43.21.105:80/"
- },
- "resourceId": "1246",
+ "id": "extVirtualLink_1",
+ "vimConnectionId": "vimConnection_1",
+ "resourceProviderId": "resourceProvider_1",
+ "resourceId": "resource_1",
+ "resourceSubnetId": "resourceSubnet_1",
"extCps": [
{
- "cpdId": "11",
- "addresses": [
- {
- "addressType": "MAC",
- "l2AddressData": "00:f3:43:20:a2:a3"
- },
+ "cpdId": "cpd_1",
+ "cpConfig": [
{
- "addressType": "IP",
- "l3AddressData": {
- "iPAddressType": "IPv4",
- "iPAddress": "192.168.104.2"
- }
+ "cpInstanceId": "cpInstance_1",
+ "linkPortId": "linkPort_1",
+ "cpProtocolData": [
+ {
+ "layerProtocol": "IP_OVER_ETHERNET",
+ "ipOverEthernet": {
+ "macAddress": "00:f3:43:20:a2:a3",
+ "ipAddresses": [
+ {
+ "type": "IPV4",
+ "fixedAddresses": ["192.168.104.2", ],
+ "numDynamicAddresses": 0,
+ "addressRange": None,
+ "subnetId": "subnet_1",
+ }
+ ]
+ }
+ }
+ ]
}
- ],
- "numDynamicAddresses": 0
+ ]
+ }
+ ],
+ "extLinkPorts": [
+ {
+ "id": "extLinkPort_1",
+ "resourceHandle": {
+ "vimConnectionId": "vimConnection_1",
+ "resourceProviderId": "resourceProvider_1",
+ "resourceId": "resource_1",
+ "vimLevelResourceType": "vimLevelResourceType_1",
+ }
}
]
- },
+ }
+ ],
+ "extManagedVirtualLinks": [
{
- "vlInstanceId": '55',
- "resourceId": '55_network',
- "resourceSubnetId": '55_subnet',
- "cpdId": 'cpId1',
- "vim": {
- "vimId": '55_vimid'
- }
+ "id": 'extManagedVirtualLink_1',
+ "virtualLinkDescId": 'virtualLinkDesc_1',
+ "vimConnectionId": 'vimConnection_1',
+ "resourceProviderId": 'resourceProvider_1',
+ "resourceId": 'resource_1',
+ }
+ ],
+ "vimConnectionInfo": [
+ {
+ "id": 'vimConnection_1',
+ "vimId": 'vim_1',
+ "vimType": 'vim',
+ "interfaceInfo": {
+ "apiVersion": "apiVersion_1",
+ "protocolType": "http"
+ },
+ "accessInfo": {
+ "tenant": "tenant_vCPE",
+ "username": "vCPE",
+ "password": "vCPE_321",
+ },
+ "extra": None,
}
],
"localizationLanguage": "en_US",
"additionalParams": {
"vimId": "vim_1",
- "inputs": {
- "key1": "test1",
- "key2": "test2"
- },
- "extVirtualLinks": [
- {
- "vlInstanceId": '55',
- "resourceId": '55_network',
- "resourceSubnetId": '55_subnet',
- "cpdId": 'cpId1',
- "vim": {
- "vimId": '55_vimid'
- }
- }
- ]
+ "key1": "test1",
+ "key2": "test2",
}
}
"tenants": [
{
"id": "1",
- "name": "tenantname_1"
+ "name": "chinamobile"
}
]
}
}
vnfdModel = {
- "volume_storages": [],
+ "volume_storages": [
+ {
+ "volume_storage_id": "test",
+ "properties": {
+ "location_info": {
+ "vimid": "vim_1",
+ "tenant": "chinamobile",
+ "availability_zone": "test",
+ },
+ "volume_name": "test",
+ "custom_volume_type": "test",
+ "size": "10 GB",
+ },
+ "image_file": "test",
+ },
+ ],
+ "vls": [
+ {
+ "vl_id": "test",
+ "properties": {
+ "location_info": {
+ "vimid": "test",
+ "tenant": "chinamobile",
+ },
+ "vl_profile": {
+ "networkName": "test",
+ "networkType": "test",
+ "physicalNetwork": "test",
+ "vlanTransparent": "test",
+ "segmentationId": "1",
+ "cidr": "test",
+ "dhcpEnabled": "test",
+ "gatewayIp": "test",
+ "startIp": "test",
+ "endIp": "test",
+ },
+ "connectivity_type": {
+ "layer_protocol": "ipv4",
+ },
+ "dns_nameservers": "test",
+ "host_routes": "test",
+ },
+ "route_external": "test",
+ }
+ ],
+ "cps": [
+ {
+ "vdu_id": "test",
+ "cp_id": "cp1",
+ "networkId": "", # TODO
+ "subnetId": "", # TODO
+ "vl_id": "test",
+ "properties": {
+ "name": "test",
+ "mac_address": "test",
+ "protocol_data": [
+ {
+ "address_data": {
+ "l3_address_data": {
+ "fixed_ip_address": "test"
+ },
+ },
+ },
+ ],
+ "vnic_type": "test",
+ }
+ }
+ ],
+ "vdus": [
+ {
+ "vdu_id": "test",
+ "properties": {
+ "location_info": {
+ "vimid": "test",
+ "tenant": "chinamobile",
+ "availability_zone": "test",
+ },
+ "name": "test",
+ "inject_files": [],
+ "user_data": "test",
+ "meta_data": {},
+ },
+ "cps": [],
+ "type": "tosca.nodes.nfv.Vdu.Compute",
+ "virtual_compute": {
+ "virtual_cpu": {
+ "num_virtual_cpu": "16",
+ },
+ "virtual_memory": {
+ "virtual_mem_size": "8000 MB",
+ "vdu_memory_requirements": {
+ "memoryPageSize": "8 MB",
+ },
+ },
+ },
+ "virtual_storage": {
+ "type_of_storage": "ephemeral",
+ "size_of_storage": "10 GB",
+ },
+ "type": "tosca.nodes.nfv.Vdu.Compute",
+ "artifacts": [
+ {
+ "artifact_name": "sw_image",
+ "file": "sss.vmdk",
+ },
+ ],
+ "volume_storages": [
+ {
+ "volume_storage_id": "test",
+ }
+ ],
+ },
+ ],
+ "image_files": [],
+ "routers": [],
+ "local_storages": [],
+ "vnf_exposed": {
+ "external_cps": [],
+ "forward_cps": []
+ },
"inputs": {
"pe1_id": {
"type": "string",
"description": "Nameofunderlayervpn"
}
},
- "vdus": [],
- "image_files": [],
- "routers": [],
- "local_storages": [],
- "vnf_exposed": {
- "external_cps": [],
- "forward_cps": []
- },
- "vls": [],
- "cps": [],
"metadata": {
"designer": "sdno",
"name": "underlayervpn",