Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestion: Integrate two different methods to register image/spec #197

Open
jihoon-seo opened this issue Jul 7, 2020 · 2 comments
Open
Labels
feature request Issue related with new feature

Comments

@jihoon-seo
Copy link
Member

Related issue: #196

As-is:
There are two different methods to register image/spec

  • POST /:nsId/resources/image?action=registerWithInfo
  • POST /:nsId/resources/image?action=registerWithId

To-be:
Integrate two different methods

  • POST /:nsId/resources/image

[Logic of integrated func RegisterImage()]

  1. If the request body contains only name, connectionName and cspImageId
{
    "name": "{{name}}",
    "connectionName": "{{connection_name}}",
    "cspImageId": "{{cspImageId}}"    
}

→ Lookup image info via CB-Spider using cspImageId and connectionName, and register a TB image object.

  1. If the request body has rich info
{
    "name": "IMAGE-01",
    "connectionName": "aws-us-east-1-config",
    "cspImageId": "ami-07ebfd5b3428b6f4d",
    "cspImageName": "ubuntu/images/hvm-ssd/ubuntu-bionic-18.04-amd64-server-20190814",
    "creationDate": "2019-08-19T18:11:28.000Z",
    "description": "Canonical, Ubuntu, 18.04 LTS, amd64 bionic image build on 2019-08-14",
    "guestOS": "",
    "status": "",
	  "keyValueList": [
	        {
	            "Key": "key1, written in Postman req",
	            "Value": "value1, written in Postman req"
	        },
	        {
	            "Key": "key2, written in Postman req",
	            "Value": "value2, written in Postman req"
	        }
	    ]
}

→ Register a TB image object with given info.

@issue-label-bot
Copy link

Issue-Label Bot is automatically applying the label feature_request to this issue, with a confidence of 0.63. Please mark this comment with 👍 or 👎 to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

@issue-label-bot issue-label-bot bot added the feature request Issue related with new feature label Jul 7, 2020
@jihoon-seo
Copy link
Member Author

As of 2020-09-04:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Issue related with new feature
Projects
None yet
Development

No branches or pull requests

1 participant