Skip to content

Commit

Permalink
Merge pull request #913 from jihoon-seo/211102_Add_KTcloud_info
Browse files Browse the repository at this point in the history
Add KTcloud info
  • Loading branch information
seokho-son authored Nov 3, 2021
2 parents 17480ab + 86637ab commit a3a993a
Show file tree
Hide file tree
Showing 6 changed files with 153 additions and 32 deletions.
18 changes: 12 additions & 6 deletions src/api/rest/docs/docs.go
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
// Package docs GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
// This file was generated by swaggo/swag

package docs

import (
"bytes"
"encoding/json"
"strings"
"text/template"

"github.com/alecthomas/template"
"github.com/swaggo/swag"
)

var doc = `{
"schemes": {{ marshal .Schemes }},
"swagger": "2.0",
"info": {
"description": "{{.Description}}",
"description": "{{escape .Description}}",
"title": "{{.Title}}",
"contact": {
"name": "API Support",
Expand Down Expand Up @@ -1428,7 +1427,7 @@ var doc = `{
"required": true
},
{
"description": "Details for an MCIS object",
"description": "Details for MCIS object",
"name": "mcisReq",
"in": "body",
"required": true,
Expand Down Expand Up @@ -6796,6 +6795,13 @@ func (s *s) ReadDoc() string {
a, _ := json.Marshal(v)
return string(a)
},
"escape": func(v interface{}) string {
// escape tabs
str := strings.Replace(v.(string), "\t", "\\t", -1)
// replace " with \", and if that results in \\", replace that with \\\"
str = strings.Replace(str, "\"", "\\\"", -1)
return strings.Replace(str, "\\\\\"", "\\\\\\\"", -1)
},
}).Parse(doc)
if err != nil {
return doc
Expand All @@ -6810,5 +6816,5 @@ func (s *s) ReadDoc() string {
}

func init() {
swag.Register(swag.Name, &s{})
swag.Register("swagger", &s{})
}
2 changes: 1 addition & 1 deletion src/api/rest/docs/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -1413,7 +1413,7 @@
"required": true
},
{
"description": "Details for an MCIS object",
"description": "Details for MCIS object",
"name": "mcisReq",
"in": "body",
"required": true,
Expand Down
2 changes: 1 addition & 1 deletion src/api/rest/docs/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2549,7 +2549,7 @@ paths:
name: nsId
required: true
type: string
- description: Details for an MCIS object
- description: Details for MCIS object
in: body
name: mcisReq
required: true
Expand Down
133 changes: 110 additions & 23 deletions src/testclient/scripts/conf.env
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ IY=0
ProviderName[$IX]=AWS
DriverLibFileName[$IX]=aws-driver-v1.0.so
DriverName[$IX]=aws-driver01
CommonImageType[$IX]="Ubuntu 18.04"

# region01
IY=$AwsApSoutheast1
Expand All @@ -47,7 +48,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-southeast-1a
CONN_CONFIG[$IX,$IY]=aws-ap-southeast-1
IMAGE_NAME[$IX,$IY]=ami-061eb2b23f9f8839c #Ubuntu 18.04
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04" #Ubuntu 18.04
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=m4.4xlarge # t2.micro t3.xlarge t3.medium

# region02
Expand All @@ -61,7 +62,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ca-central-1a
CONN_CONFIG[$IX,$IY]=aws-ca-central-1
IMAGE_NAME[$IX,$IY]=ami-0d0eaed20348a3389
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region03
Expand All @@ -75,7 +76,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=us-west-1a
CONN_CONFIG[$IX,$IY]=aws-us-west-1
IMAGE_NAME[$IX,$IY]=ami-0dd655843c87b6930
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region04
Expand All @@ -89,7 +90,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=us-east-1a
CONN_CONFIG[$IX,$IY]=aws-us-east-1
IMAGE_NAME[$IX,$IY]=ami-085925f297f89fce1
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region05
Expand All @@ -103,7 +104,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-northeast-1a
CONN_CONFIG[$IX,$IY]=aws-ap-northeast-1
IMAGE_NAME[$IX,$IY]=ami-0cd744adeca97abb1
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=m4.4xlarge #t3.xlarge t3.medium

# region06
Expand All @@ -117,7 +118,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-south-1a
CONN_CONFIG[$IX,$IY]=aws-ap-south-1
IMAGE_NAME[$IX,$IY]=ami-0123b531fc646552f
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region07
Expand All @@ -131,7 +132,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-southeast-2a
CONN_CONFIG[$IX,$IY]=aws-ap-southeast-2
IMAGE_NAME[$IX,$IY]=ami-00a54827eb7ffcd3c
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region08
Expand All @@ -145,7 +146,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-west-2a
CONN_CONFIG[$IX,$IY]=aws-eu-west-2
IMAGE_NAME[$IX,$IY]=ami-0be057a22c63962cb
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region09
Expand All @@ -159,7 +160,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=us-east-2a
CONN_CONFIG[$IX,$IY]=aws-us-east-2
IMAGE_NAME[$IX,$IY]=ami-01e7ca2ef94a0ae86
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region10
Expand All @@ -173,7 +174,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=us-west-2a
CONN_CONFIG[$IX,$IY]=aws-us-west-2
IMAGE_NAME[$IX,$IY]=ami-02701bcdc5509e57b
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region11
Expand All @@ -187,7 +188,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-northeast-3a
CONN_CONFIG[$IX,$IY]=aws-ap-northeast-3
IMAGE_NAME[$IX,$IY]=ami-0e958e6a9363c29ad
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region12
Expand All @@ -201,7 +202,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-central-1a
CONN_CONFIG[$IX,$IY]=aws-eu-central-1
IMAGE_NAME[$IX,$IY]=ami-0e0102e3ff768559b
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region13
Expand All @@ -215,7 +216,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-west-1a
CONN_CONFIG[$IX,$IY]=aws-eu-west-1
IMAGE_NAME[$IX,$IY]=ami-06fd78dc2f0b69910
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region14
Expand All @@ -229,7 +230,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-west-3a
CONN_CONFIG[$IX,$IY]=aws-eu-west-3
IMAGE_NAME[$IX,$IY]=ami-0a0d71ff90f62f72a
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region15
Expand All @@ -243,7 +244,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-north-1a
CONN_CONFIG[$IX,$IY]=aws-eu-north-1
IMAGE_NAME[$IX,$IY]=ami-0f269726c071d0e96
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t3.micro

# region16
Expand All @@ -257,7 +258,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=sa-east-1a
CONN_CONFIG[$IX,$IY]=aws-sa-east-1
IMAGE_NAME[$IX,$IY]=ami-0bd91caaa9bc42cf3
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro

# region17
Expand All @@ -271,7 +272,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-northeast-2a
CONN_CONFIG[$IX,$IY]=aws-ap-northeast-2
IMAGE_NAME[$IX,$IY]=ami-00379ec40a3e30f87
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t2.micro # m4.4xlarge

# region18
Expand All @@ -285,7 +286,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=ap-east-1a
CONN_CONFIG[$IX,$IY]=aws-ap-east-1
IMAGE_NAME[$IX,$IY]=ami-036915aa0cb1d91a1
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t3.micro

# region19
Expand All @@ -299,7 +300,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=me-south-1b
CONN_CONFIG[$IX,$IY]=aws-me-south-1
IMAGE_NAME[$IX,$IY]=ami-026dde872642a6ffe
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t3.micro

# region20
Expand All @@ -313,7 +314,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=af-south-1b
CONN_CONFIG[$IX,$IY]=aws-af-south-1
IMAGE_NAME[$IX,$IY]=ami-0e4b4778694305983
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t3.micro

# region21
Expand All @@ -327,7 +328,7 @@ RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eu-south-1b
CONN_CONFIG[$IX,$IY]=aws-eu-south-1
IMAGE_NAME[$IX,$IY]=ami-0f274cb646afd3475
IMAGE_TYPE[$IX,$IY]="Ubuntu 18.04"
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=t3.micro


Expand Down Expand Up @@ -2014,6 +2015,86 @@ SPEC_NAME[$IX,$IY]=${CommonSpec[$IX]}



###########################################
## KTcloud (5 Regions)
IX=$IndexKTcloud
ProviderName[$IX]=KTCLOUD
DriverLibFileName[$IX]=ktcloud-driver-v1.0.so
DriverName[$IX]=ktcloud-driver01
CommonImageType[$IX]="Ubuntu 18.04"


# region01
IY=$KTcloudKRcentralA
# Location: Cheon-an, South Korea
RegionLocation[$IX,$IY]="Cheon-an, South Korea"
RegionName[$IX,$IY]=kt-kr-central-a
RegionKey01[$IX,$IY]=Region
RegionVal01[$IX,$IY]=KOR-Cheonan
RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=eceb5d65-6571-4696-875f-5a17949f3317
CONN_CONFIG[$IX,$IY]=kt-kr-central-a
IMAGE_NAME[$IX,$IY]=
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=

# region02
IY=$KTcloudKRcentralB
# Location: Cheon-an, South Korea
RegionLocation[$IX,$IY]="Cheon-an, South Korea"
RegionName[$IX,$IY]=kt-kr-central-b
RegionKey01[$IX,$IY]=Region
RegionVal01[$IX,$IY]=KOR-Cheonan
RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=9845bd17-d438-4bde-816d-1b12f37d5080
CONN_CONFIG[$IX,$IY]=kt-kr-central-b
IMAGE_NAME[$IX,$IY]=
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=

# region03
IY=$KTcloudKRSeoulM
# Location: Seoul, South Korea
RegionLocation[$IX,$IY]="Seoul, South Korea"
RegionName[$IX,$IY]=kt-kr-seoul-m
RegionKey01[$IX,$IY]=Region
RegionVal01[$IX,$IY]=KOR-Seoul
RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=95e2f517-d64a-4866-8585-5177c256f7c7
CONN_CONFIG[$IX,$IY]=kt-kr-seoul-m
IMAGE_NAME[$IX,$IY]=
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=

# region04
IY=$KTcloudKRSeoulM2
# Location: Seoul, South Korea
RegionLocation[$IX,$IY]="Seoul, South Korea"
RegionName[$IX,$IY]=kt-kr-seoul-m2
RegionKey01[$IX,$IY]=Region
RegionVal01[$IX,$IY]=KOR-Seoul
RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=d7d0177e-6cda-404a-a46f-a5b356d2874e
CONN_CONFIG[$IX,$IY]=kt-kr-seoul-m2
IMAGE_NAME[$IX,$IY]=
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=

# region05
IY=$KTcloudUSwest
# Location: LA, US
RegionLocation[$IX,$IY]="LA, US"
RegionName[$IX,$IY]=kt-us-west
RegionKey01[$IX,$IY]=Region
RegionVal01[$IX,$IY]=US
RegionKey02[$IX,$IY]=Zone
RegionVal02[$IX,$IY]=b7eb18c8-876d-4dc6-9215-3bd455bb05be
CONN_CONFIG[$IX,$IY]=kt-us-west
IMAGE_NAME[$IX,$IY]=
IMAGE_TYPE[$IX,$IY]=${CommonImageType[$IX]}
SPEC_NAME[$IX,$IY]=





Expand Down Expand Up @@ -2199,6 +2280,9 @@ function getCloudIndex()
elif [ "${CSP}" == "tencent" ]; then
# echo "[Tencent driver]"
CSPIndex=$IndexTencent
elif [ "${CSP}" == "ktcloud" ]; then
# echo "[KTcloud driver]"
CSPIndex=$IndexKTcloud
else
echo "[No acceptable argument was provided (all, aws, azure, gcp, alibaba, mock, openstack, ...).]"
exit
Expand Down Expand Up @@ -2251,10 +2335,13 @@ function getCloudIndexGeneral()
CSPIndex=l
elif [ "${CSP}" == "cloudit" ]; then
# echo "[Cloudit driver]"
CSPIndex=n
CSPIndex=m
elif [ "${CSP}" == "tencent" ]; then
# echo "[Tencent driver]"
CSPIndex=m
CSPIndex=n
elif [ "${CSP}" == "ktcloud" ]; then
# echo "[KTcloud driver]"
CSPIndex=o
else
echo "[No acceptable argument was provided (all, aws, azure, gcp, alibaba, mock, openstack, ...).]"
exit
Expand Down
Loading

0 comments on commit a3a993a

Please sign in to comment.