...
Code Block | ||
---|---|---|
| ||
{ "cloud-region": "krd", "profile-name": "p1", "rb-name":"test-rbdef", "rb-version":"v1", "override-parameters": { "optionalDictOfParameters": "andTheirValues, like", "global.name": "dummy-name" }, "labels": { "optionalLabelForInternalK8spluginInstancesMetadata": "dummy-value" } } |
NOTE: Make sure that the namespace is already created before instantiation.
See
Jira Legacy | ||||||
---|---|---|---|---|---|---|
|
Instantiate the profile with the ID provided above
...
language | bash |
---|---|
title | Command to Instantiate a Profile |
...
Instantiate the profile with the ID provided above
Code Block | ||||
---|---|---|---|---|
| ||||
curl -d @create_rbinstance.json http://NODE_IP:30280/api/multicloud-k8s/v1/v1/instance |
...
Code Block | ||
---|---|---|
| ||
{ "id": "ZKMTSaxv", "rb-name": "mongo", "rb-version": "v1", "profile-name": "profile1", "cloud-region": "kud", "namespace": "testns", "resources": [ { "GVK": {ID_GENERATED_BY_K8SPLUGIN", "namespace": "NAMESPACE_WHERE_INSTANCE_HAS_BEEN_DEPLOYED_AS_DERIVED_FROM_PROFILE", "request": { "rb-name": "test-rbdef", "rb-version": "v1", "profile-name": "p1", "cloud-region": "krd", "override-parameters": { "optionalDictOfParameters": "andTheirValues, like", "global.name": "dummy-name" }, "labels": { "optionalLabelForInternalK8spluginInstancesMetadata": "dummy-value" }, } "resources": [ { "GVK": { "Group": "", "Kind": "ConfigMap", "Version": "v1" }, "Name": "test-cm" }, { "GVK": { "Group": "", "Kind": "Service", "Version": "v1" }, "Name": "test-svc" }, "Group": "", "Version": "v1", "Kind": "Service" }, "Name": "mongo" }, { "GVK": { "Group": "", { "Version": "v1", "KindGVK": "Service"{ }, "NameGroup": "mongo-readapps", }, { "GVKKind": {"Deployment", "Group": "apps", "Version": "v1beta1v1", "Kind": "StatefulSet" }, }, "Name": "profile1test-mongodep" } ] } |
Delete Instantiated Kubernetes resources
...
The id field from the returned JSON can be used to GET the resources created in the previous step
This executes a Delete operation using the Kubernetes API.
Code Block | ||||
---|---|---|---|---|
| ||||
curl -X GET http://NODE_IP:30280/api/multicloud-k8s/v1/v1/instance/ZKMTSaxv |
Output of this call conforms to the same schema and contains (currently) same information as instantiation response (described above)
LIST all Instantiated Kubernetes resources
...