Loading modules/cloud_dashboard/cloud_dashboard/src/constant/launch_template.ts +12 −2 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/launch_template.ts: 12 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -30,6 +30,11 @@ const K8S_LAUNCH_TEMPLATE_LIST: EntityColumn[] = [ const DEFAULT_K8S_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' }; // Template for displaying the Launch template in OpenStack. const OPENSTACK_LAUNCH_TEMPLATE_LIST: EntityColumn[] = []; const DEFAULT_OPENSTACK_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' }; /** * Get LaunchTemplateColumnList by cloud_context. * Loading @@ -52,8 +57,13 @@ const getLaunchTemplateColumnList = (cloudContext: CloudContext): EntityColumn[] DEFAULT_K8S_LAUNCH_TEMPLATE, ...K8S_LAUNCH_TEMPLATE_LIST ]; default: throw new Error('It is an unknown Cloud Context.'); case 'openstack': return cloudContext.name !== 'ALL' ? OPENSTACK_LAUNCH_TEMPLATE_LIST : [ DEFAULT_OPENSTACK_LAUNCH_TEMPLATE, ...OPENSTACK_LAUNCH_TEMPLATE_LIST ]; } }; Loading modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.json +302 −0 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.json: 302 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -1577,5 +1577,307 @@ } ] } ], [ { "cloudServiceProvider": "openstack", "labelName": "Instances", "entityName": "instance", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Image", "name": "image_id", "type": "default" }, { "labelName": "Public IP", "name": "public_ip", "type": "join", "info": { "entityTypeId": "openstack_floating_ip", "keyColumn": "public_ip", "valueColumn": "name" } }, { "labelName": "Instance State", "name": "instance_state", "type": "default" }, { "labelName": "Flavor", "name": "instance_type", "type": "default" }, { "labelName": "Availability Zone", "name": "availability_zone", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Images", "entityName": "image", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "AMI Name", "name": "ami_name", "type": "default" }, { "labelName": "AMI ID", "name": "image_id", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Source", "name": "source", "type": "default" }, { "labelName": "Root Device Type", "name": "root_device_type", "type": "default" }, { "labelName": "Visibility", "name": "visibility", "type": "boolean", "value": [ "Public", "Private" ] }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Security groups", "entityName": "security_group", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Group ID", "name": "group_id", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Floating IPs", "entityName": "floating_ip", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Allocation ID", "name": "allocation_id", "type": "default" }, { "labelName": "Floating IP", "name": "public_ip", "type": "default" }, { "labelName": "Instance ID", "name": "instance_id", "type": "join", "info": { "entityTypeId": "openstack_instance", "keyColumn": "instance_id", "valueColumn": "name" } }, { "labelName": "Private IP Address", "name": "private_ip_address", "type": "default" }, { "labelName": "Scope", "name": "scope", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Network interfaces", "entityName": "network_interface", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Subnet ID", "name": "subnet_id", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Security groups", "name": "security_groups", "type": "join", "info": { "entityTypeId": "openstack_security_group", "keyColumn": "name", "valueColumn": "name" } }, { "labelName": "Primary Private IP", "name": "primary_private_ip", "type": "default" }, { "labelName": "Secondary Private IPs", "name": "secondary_private_ips", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Key pairs", "entityName": "key_pair", "entityColumn": [ { "labelName": "Key pair name", "name": "key_pair_name", "type": "default" }, { "labelName": "Key Fingerprint", "name": "key_fingerprint", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Volumes", "entityName": "volume", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Volume ID", "name": "volume_id", "type": "default" }, { "labelName": "Size", "name": "size", "type": "default" }, { "labelName": "Availability Zone", "name": "availability_zone", "type": "default" }, { "labelName": "Volume type", "name": "volume_type", "type": "default" }, { "labelName": "Attachment Information", "name": "attachment_information", "type": "join", "info": { "entityTypeId": "openstack_instance", "keyColumn": "instance_id", "valueColumn": "name" } }, { "labelName": "State", "name": "state", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Snapshots", "entityName": "snapshot", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Snapshot ID", "name": "snapshot_id", "type": "default" }, { "labelName": "Size", "name": "size", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] } ] ] modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.ts +6 −3 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.ts: 6 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -8,7 +8,10 @@ const AWS_MENU_LIST = menu_template[0] as MenuTemplate[]; // Template for displaying a list of entities in K8s. const K8S_MENU_LIST = menu_template[1] as MenuTemplate[]; export const MENU_TEMPLATE_LIST = [...AWS_MENU_LIST, ...K8S_MENU_LIST]; // Template for displaying a list of entities in OpenStack. const OPENSTACK_MENU_LIST = menu_template[2] as MenuTemplate[]; export const MENU_TEMPLATE_LIST = [...AWS_MENU_LIST, ...K8S_MENU_LIST, ...OPENSTACK_MENU_LIST]; export const getMenuTemplateList = (cloudServiceProvider: CloudServiceProvider) => { switch (cloudServiceProvider) { Loading @@ -16,7 +19,7 @@ export const getMenuTemplateList = (cloudServiceProvider: CloudServiceProvider) return AWS_MENU_LIST; case 'k8s': return K8S_MENU_LIST; default: throw new Error('It is an unknown Cloud Context.'); case 'openstack': return OPENSTACK_MENU_LIST; } } modules/cloud_dashboard/cloud_dashboard/src/constant/other.ts +2 −1 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/other.ts: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -25,8 +25,9 @@ export const CACHE_EXPIRED_UNIXTIME = 1000 * 60 * 60 * 24; export const DEFAULT_CLOUD_CONTEXTS: CloudContext[] = [ { cloudServiceProvider: 'aws_cloud', name: 'ALL', labelName: 'AWS Cloud (ALL)' }, { cloudServiceProvider: 'k8s', name: 'ALL', labelName: 'K8s (ALL)' }, { cloudServiceProvider: 'openstack', name: 'ALL', labelName: 'OpenStack (ALL)' }, ]; export const CLOUD_SERVICE_PROVIDER_LIST: CloudServiceProvider[] = [ 'aws_cloud', 'k8s' 'aws_cloud', 'k8s', 'openstack', ]; modules/cloud_dashboard/cloud_dashboard/src/constant/project_template.ts +2 −0 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/project_template.ts: 2 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -25,6 +25,8 @@ export const getProjectColumnList = (cloudContext: CloudContext): EntityColumn[] switch (cloudContext.cloudServiceProvider) { case 'aws_cloud': return []; case 'openstack': return []; case 'k8s': return cloudContext.name !== 'ALL' ? K8S_PROJECT_TEMPLATE_LIST Loading Loading
modules/cloud_dashboard/cloud_dashboard/src/constant/launch_template.ts +12 −2 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/launch_template.ts: 12 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -30,6 +30,11 @@ const K8S_LAUNCH_TEMPLATE_LIST: EntityColumn[] = [ const DEFAULT_K8S_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' }; // Template for displaying the Launch template in OpenStack. const OPENSTACK_LAUNCH_TEMPLATE_LIST: EntityColumn[] = []; const DEFAULT_OPENSTACK_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' }; /** * Get LaunchTemplateColumnList by cloud_context. * Loading @@ -52,8 +57,13 @@ const getLaunchTemplateColumnList = (cloudContext: CloudContext): EntityColumn[] DEFAULT_K8S_LAUNCH_TEMPLATE, ...K8S_LAUNCH_TEMPLATE_LIST ]; default: throw new Error('It is an unknown Cloud Context.'); case 'openstack': return cloudContext.name !== 'ALL' ? OPENSTACK_LAUNCH_TEMPLATE_LIST : [ DEFAULT_OPENSTACK_LAUNCH_TEMPLATE, ...OPENSTACK_LAUNCH_TEMPLATE_LIST ]; } }; Loading
modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.json +302 −0 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.json: 302 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -1577,5 +1577,307 @@ } ] } ], [ { "cloudServiceProvider": "openstack", "labelName": "Instances", "entityName": "instance", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Image", "name": "image_id", "type": "default" }, { "labelName": "Public IP", "name": "public_ip", "type": "join", "info": { "entityTypeId": "openstack_floating_ip", "keyColumn": "public_ip", "valueColumn": "name" } }, { "labelName": "Instance State", "name": "instance_state", "type": "default" }, { "labelName": "Flavor", "name": "instance_type", "type": "default" }, { "labelName": "Availability Zone", "name": "availability_zone", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Images", "entityName": "image", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "AMI Name", "name": "ami_name", "type": "default" }, { "labelName": "AMI ID", "name": "image_id", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Source", "name": "source", "type": "default" }, { "labelName": "Root Device Type", "name": "root_device_type", "type": "default" }, { "labelName": "Visibility", "name": "visibility", "type": "boolean", "value": [ "Public", "Private" ] }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Security groups", "entityName": "security_group", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Group ID", "name": "group_id", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Floating IPs", "entityName": "floating_ip", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Allocation ID", "name": "allocation_id", "type": "default" }, { "labelName": "Floating IP", "name": "public_ip", "type": "default" }, { "labelName": "Instance ID", "name": "instance_id", "type": "join", "info": { "entityTypeId": "openstack_instance", "keyColumn": "instance_id", "valueColumn": "name" } }, { "labelName": "Private IP Address", "name": "private_ip_address", "type": "default" }, { "labelName": "Scope", "name": "scope", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Network interfaces", "entityName": "network_interface", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Subnet ID", "name": "subnet_id", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Security groups", "name": "security_groups", "type": "join", "info": { "entityTypeId": "openstack_security_group", "keyColumn": "name", "valueColumn": "name" } }, { "labelName": "Primary Private IP", "name": "primary_private_ip", "type": "default" }, { "labelName": "Secondary Private IPs", "name": "secondary_private_ips", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Key pairs", "entityName": "key_pair", "entityColumn": [ { "labelName": "Key pair name", "name": "key_pair_name", "type": "default" }, { "labelName": "Key Fingerprint", "name": "key_fingerprint", "type": "default" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Volumes", "entityName": "volume", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Volume ID", "name": "volume_id", "type": "default" }, { "labelName": "Size", "name": "size", "type": "default" }, { "labelName": "Availability Zone", "name": "availability_zone", "type": "default" }, { "labelName": "Volume type", "name": "volume_type", "type": "default" }, { "labelName": "Attachment Information", "name": "attachment_information", "type": "join", "info": { "entityTypeId": "openstack_instance", "keyColumn": "instance_id", "valueColumn": "name" } }, { "labelName": "State", "name": "state", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] }, { "cloudServiceProvider": "openstack", "labelName": "Snapshots", "entityName": "snapshot", "entityColumn": [ { "labelName": "Name", "name": "name", "type": "default" }, { "labelName": "Snapshot ID", "name": "snapshot_id", "type": "default" }, { "labelName": "Size", "name": "size", "type": "default" }, { "labelName": "Status", "name": "status", "type": "default" }, { "labelName": "Created", "name": "created", "type": "datetime" } ] } ] ]
modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.ts +6 −3 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/menu_template.ts: 6 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -8,7 +8,10 @@ const AWS_MENU_LIST = menu_template[0] as MenuTemplate[]; // Template for displaying a list of entities in K8s. const K8S_MENU_LIST = menu_template[1] as MenuTemplate[]; export const MENU_TEMPLATE_LIST = [...AWS_MENU_LIST, ...K8S_MENU_LIST]; // Template for displaying a list of entities in OpenStack. const OPENSTACK_MENU_LIST = menu_template[2] as MenuTemplate[]; export const MENU_TEMPLATE_LIST = [...AWS_MENU_LIST, ...K8S_MENU_LIST, ...OPENSTACK_MENU_LIST]; export const getMenuTemplateList = (cloudServiceProvider: CloudServiceProvider) => { switch (cloudServiceProvider) { Loading @@ -16,7 +19,7 @@ export const getMenuTemplateList = (cloudServiceProvider: CloudServiceProvider) return AWS_MENU_LIST; case 'k8s': return K8S_MENU_LIST; default: throw new Error('It is an unknown Cloud Context.'); case 'openstack': return OPENSTACK_MENU_LIST; } }
modules/cloud_dashboard/cloud_dashboard/src/constant/other.ts +2 −1 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/other.ts: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -25,8 +25,9 @@ export const CACHE_EXPIRED_UNIXTIME = 1000 * 60 * 60 * 24; export const DEFAULT_CLOUD_CONTEXTS: CloudContext[] = [ { cloudServiceProvider: 'aws_cloud', name: 'ALL', labelName: 'AWS Cloud (ALL)' }, { cloudServiceProvider: 'k8s', name: 'ALL', labelName: 'K8s (ALL)' }, { cloudServiceProvider: 'openstack', name: 'ALL', labelName: 'OpenStack (ALL)' }, ]; export const CLOUD_SERVICE_PROVIDER_LIST: CloudServiceProvider[] = [ 'aws_cloud', 'k8s' 'aws_cloud', 'k8s', 'openstack', ];
modules/cloud_dashboard/cloud_dashboard/src/constant/project_template.ts +2 −0 Changes for modules/cloud_dashboard/cloud_dashboard/src/constant/project_template.ts: 2 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -25,6 +25,8 @@ export const getProjectColumnList = (cloudContext: CloudContext): EntityColumn[] switch (cloudContext.cloudServiceProvider) { case 'aws_cloud': return []; case 'openstack': return []; case 'k8s': return cloudContext.name !== 'ALL' ? K8S_PROJECT_TEMPLATE_LIST Loading