Ask Your Question
0

uploading images to glance using curl

asked 2011-06-23 18:33:17 -0600

diego-lalo gravatar image

updated 2015-01-18 09:34:51 -0600

Hi everyone, I'm writing this message because I want to use glance REST API to upload images and I would like to use curl to do the job, can anyone send me an example of how to build a POST request to upload images to a glance server with all the metadata?

Thanks in advance Diego

edit retag flag offensive close merge delete

4 answers

Sort by ยป oldest newest most voted
1

answered 2015-01-18 00:48:44 -0600

Richard gravatar image

I had the same question just now, so I found this page. Although it is a little bit old question, and I believe you already know the answer. I still think it is necessary to answer for those who will be searching the answer like you and me.

I think a good answer would be: Use the "--debug" option to see what the glance client posted to the glance server.

So, for example, when you issue a create command glance --debug image-create --name image1 the first line of the output would tell you the curl command it is using.

Use the same way, you can find how to upload with curl.

edit flag offensive delete link more
0

answered 2012-08-09 06:59:59 -0600

sajhak gravatar image

Hi Diego,

Were you able to get this done successfully? I'm also looking for a way to upload an image to Glance server. Could you please help me on this? Im using Openstack "Essex" version.. and i couldnt find /test/functional/test_curl_api.py mentioned above.

A web site link will be very helpful

Thanks Sajith

edit flag offensive delete link more
0

answered 2011-06-27 12:53:02 -0600

diego-lalo gravatar image

Ty very very much Jay :) :) :) I'm having a look at the tests, it's just what I need, I will launch glance-api in debug mode and I will check if something is wrong with the middleware.

Cheers Diego

edit flag offensive delete link more
0

answered 2011-06-26 17:43:38 -0600

jaypipes gravatar image

Hi Diego,

Check out the examples in /test/functional/test_curl_api.py for lots of examples of all the REST API commands over cURL.

Cheers! jay

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2011-06-23 18:33:17 -0600

Seen: 1,170 times

Last updated: Jan 18 '15