root / docs / cyclades-api-guide.rst @ 3458183d
History | View | Annotate | Download (108.5 kB)
1 | 1837aa54 | Giorgos Verigakis | .. _cyclades-api-guide: |
---|---|---|---|
2 | 1837aa54 | Giorgos Verigakis | |
3 | c3945370 | Vangelis Koukis | API Guide |
4 | c3945370 | Vangelis Koukis | ********* |
5 | c3945370 | Vangelis Koukis | |
6 | 3458183d | Constantinos Venetsanopoulos | `Cyclades <cyclades.html>`_ is the Compute Service of `Synnefo |
7 | 3458183d | Constantinos Venetsanopoulos | <http://www.synnefo.org>`_. The Cyclades API tries to be as close to the |
8 | 3458183d | Constantinos Venetsanopoulos | `OpenStack Compute API v2 |
9 | 3458183d | Constantinos Venetsanopoulos | <http://docs.openstack.org/api/openstack-compute/2/content>`_ as possible. |
10 | c3945370 | Vangelis Koukis | |
11 | 3b1963eb | Stavros Sachtouris | This document's goals are: |
12 | c3945370 | Vangelis Koukis | |
13 | 3458183d | Constantinos Venetsanopoulos | * Define the Cyclades/Compute REST API |
14 | 3458183d | Constantinos Venetsanopoulos | * Clarify the differences between Cyclades and OpenStack/Compute |
15 | 3b1963eb | Stavros Sachtouris | |
16 | 3458183d | Constantinos Venetsanopoulos | Users and developers who wish to access Cyclades through its REST API are |
17 | 3458183d | Constantinos Venetsanopoulos | advised to use the `kamaki <http://docs.dev.grnet.gr/kamaki>`_ command-line |
18 | 3458183d | Constantinos Venetsanopoulos | client and associated python library, instead of making direct calls. |
19 | 2cd1c00a | Giorgos Verigakis | |
20 | 2cd1c00a | Giorgos Verigakis | Overview |
21 | 2cd1c00a | Giorgos Verigakis | ======== |
22 | 2cd1c00a | Giorgos Verigakis | |
23 | 3458183d | Constantinos Venetsanopoulos | * OpenStack does not define if requests for invalid URLs should return 404 or a |
24 | 3458183d | Constantinos Venetsanopoulos | * Fault. We return a BadRequest Fault. |
25 | 3458183d | Constantinos Venetsanopoulos | * OpenStack does not define if requests with a wrong HTTP method should return |
26 | 3458183d | Constantinos Venetsanopoulos | * 405 or a Fault. We return a BadRequest Fault. |
27 | 2cd1c00a | Giorgos Verigakis | |
28 | 2cd1c00a | Giorgos Verigakis | General API Information |
29 | 2cd1c00a | Giorgos Verigakis | ======================= |
30 | 2cd1c00a | Giorgos Verigakis | |
31 | 2cd1c00a | Giorgos Verigakis | Authentication |
32 | 2cd1c00a | Giorgos Verigakis | -------------- |
33 | 2cd1c00a | Giorgos Verigakis | |
34 | e31f6f23 | Stavros Sachtouris | All requests use the same authentication method: an ``X-Auth-Token`` header is |
35 | e31f6f23 | Stavros Sachtouris | passed to the servive, which is used to authenticate the user and retrieve user |
36 | e31f6f23 | Stavros Sachtouris | related information. No other user details are passed through HTTP. |
37 | 2cd1c00a | Giorgos Verigakis | |
38 | 2cd1c00a | Giorgos Verigakis | Efficient Polling with the Changes-Since Parameter |
39 | 2cd1c00a | Giorgos Verigakis | -------------------------------------------------- |
40 | 2cd1c00a | Giorgos Verigakis | |
41 | a5ec880a | Stavros Sachtouris | * Effectively limit support of the changes-since parameter in **List Servers** |
42 | e31f6f23 | Stavros Sachtouris | and **List Images**. |
43 | e31f6f23 | Stavros Sachtouris | |
44 | cfdbd784 | Stavros Sachtouris | * Assume that garbage collection of deleted servers will only affect servers |
45 | e31f6f23 | Stavros Sachtouris | deleted ``POLL_TIME`` seconds (default: 3600) in the past or earlier. Else |
46 | e31f6f23 | Stavros Sachtouris | loose the information of a server getting deleted. |
47 | e31f6f23 | Stavros Sachtouris | |
48 | cfdbd784 | Stavros Sachtouris | * Images do not support a deleted state, so deletions cannot be tracked. |
49 | 2cd1c00a | Giorgos Verigakis | |
50 | e31f6f23 | Stavros Sachtouris | Limitations |
51 | e31f6f23 | Stavros Sachtouris | ----------- |
52 | 2cd1c00a | Giorgos Verigakis | |
53 | e31f6f23 | Stavros Sachtouris | * Version MIME type and vesionless requests are not currently supported. |
54 | 2cd1c00a | Giorgos Verigakis | |
55 | e31f6f23 | Stavros Sachtouris | * Cyclades only supports JSON Requests and JSON/XML Responses. XML Requests are |
56 | e31f6f23 | Stavros Sachtouris | currently not supported. |
57 | 2cd1c00a | Giorgos Verigakis | |
58 | e31f6f23 | Stavros Sachtouris | * Optional content compression support is currently not supported. |
59 | 2cd1c00a | Giorgos Verigakis | |
60 | e31f6f23 | Stavros Sachtouris | * To prevent abuse, HTTP sessions have a timeout of 20 seconds before being |
61 | e31f6f23 | Stavros Sachtouris | closed. |
62 | 2cd1c00a | Giorgos Verigakis | |
63 | e31f6f23 | Stavros Sachtouris | * Full URI references and ``self`` and ``bookmark`` links are not supported. |
64 | 2cd1c00a | Giorgos Verigakis | |
65 | e31f6f23 | Stavros Sachtouris | * Pagination is currently not supported. |
66 | 2cd1c00a | Giorgos Verigakis | |
67 | e31f6f23 | Stavros Sachtouris | * Cached responses are currently not supported. |
68 | e31f6f23 | Stavros Sachtouris | |
69 | e31f6f23 | Stavros Sachtouris | * Limits are currently not supported. |
70 | e31f6f23 | Stavros Sachtouris | |
71 | e31f6f23 | Stavros Sachtouris | * Extensions are currently not supported. |
72 | 2cd1c00a | Giorgos Verigakis | |
73 | 2cd1c00a | Giorgos Verigakis | |
74 | 2cd1c00a | Giorgos Verigakis | API Operations |
75 | 2cd1c00a | Giorgos Verigakis | ============== |
76 | 2cd1c00a | Giorgos Verigakis | |
77 | 2cd1c00a | Giorgos Verigakis | Servers |
78 | 2cd1c00a | Giorgos Verigakis | ------- |
79 | 2cd1c00a | Giorgos Verigakis | |
80 | 8a86499c | Stavros Sachtouris | =================================================== ========================================= ====== ======== ========== |
81 | 8a86499c | Stavros Sachtouris | Description URI Method Cyclades OS/Compute |
82 | 8a86499c | Stavros Sachtouris | =================================================== ========================================= ====== ======== ========== |
83 | 8a86499c | Stavros Sachtouris | `List <#list-servers>`_ ``/servers`` GET ✔ ✔ |
84 | 8a86499c | Stavros Sachtouris | \ ``/servers/detail`` GET ✔ ✔ |
85 | 8a86499c | Stavros Sachtouris | `Create <#create-server>`_ ``/servers`` POST ✔ ✔ |
86 | 8a86499c | Stavros Sachtouris | `Get Stats <#get-server-stats>`_ ``/servers/<server-id>/stats`` GET ✔ **✘** |
87 | 8a86499c | Stavros Sachtouris | `Get Diagnostics <#get-server-diagnostics>`_ ``/servers/<server-id>/diagnostics`` GET ✔ **✘** |
88 | 8a86499c | Stavros Sachtouris | `Get Details <#get-server-details>`_ ``/servers/<server id>`` GET ✔ ✔ |
89 | 8a86499c | Stavros Sachtouris | `Rename <#rename-server>`_ ``/servers/<server id>`` PUT ✔ ✔ |
90 | 8a86499c | Stavros Sachtouris | `Delete <#delete-server>`_ ``/servers/<server id>`` DELETE ✔ ✔ |
91 | 8a86499c | Stavros Sachtouris | `List Addresses <#list-server-addresses>`_ ``/servers/<server id>/ips`` GET ✔ ✔ |
92 | 8a86499c | Stavros Sachtouris | `Get NICs by Net <#get-server-nics-by-network>`_ ``/servers/<server id>/ips/<network id>`` GET ✔ ✔ |
93 | 8a86499c | Stavros Sachtouris | `List Metadata <#list-server-metadata>`_ ``/servers/<server-id>/meta`` GET ✔ **✘** |
94 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata`` GET **✘** ✔ |
95 | 8a86499c | Stavros Sachtouris | `Update Metadata <#set-update-server-metadata>`_ ``/servers/<server-id>/meta`` POST ✔ **✘** |
96 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata`` PUT **✘** ✔ |
97 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata`` POST **✘** ✔ |
98 | 8a86499c | Stavros Sachtouris | `Get Meta Item <#get-server-metadata-item>`_ ``/servers/<server-id>/meta/<key>`` GET ✔ **✘** |
99 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata/<key>`` GET **✘** ✔ |
100 | 8a86499c | Stavros Sachtouris | `Update Meta Item <#update-server-metadatum-item>`_ ``/servers/<server-id>/meta/<key>`` PUT ✔ **✘** |
101 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata/<key>`` PUT **✘** ✔ |
102 | 8a86499c | Stavros Sachtouris | `Delete Meta Item <#delete-server-metadatum>`_ ``/servers/<server-id>/meta/<key>`` DELETE ✔ **✘** |
103 | 8a86499c | Stavros Sachtouris | \ ``/servers/<server-id>/metadata/<key>`` DELETE **✘** ✔ |
104 | 8a86499c | Stavros Sachtouris | =================================================== ========================================= ====== ======== ========== |
105 | 8a86499c | Stavros Sachtouris | |
106 | 2cd1c00a | Giorgos Verigakis | List Servers |
107 | 2cd1c00a | Giorgos Verigakis | ............ |
108 | 2cd1c00a | Giorgos Verigakis | |
109 | 02242022 | Stavros Sachtouris | List all virtual servers owned by the user. |
110 | 02242022 | Stavros Sachtouris | |
111 | 02242022 | Stavros Sachtouris | .. rubric:: Request |
112 | 02242022 | Stavros Sachtouris | |
113 | 3b1963eb | Stavros Sachtouris | =================== ====== ======== ========== |
114 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
115 | 3b1963eb | Stavros Sachtouris | =================== ====== ======== ========== |
116 | 3b1963eb | Stavros Sachtouris | ``/servers`` GET ✔ ✔ |
117 | e74edfbb | Stavros Sachtouris | ``/servers/detail`` GET ✔ ✔ |
118 | 3b1963eb | Stavros Sachtouris | =================== ====== ======== ========== |
119 | 3b1963eb | Stavros Sachtouris | |
120 | a5ec880a | Stavros Sachtouris | * Both requests return a list of servers. The first returns just ``id`` and |
121 | e31f6f23 | Stavros Sachtouris | ``name``, while the second returns the full collections of server |
122 | e31f6f23 | Stavros Sachtouris | attributes. |
123 | 3b1963eb | Stavros Sachtouris | |
124 | 02242022 | Stavros Sachtouris | | |
125 | 02242022 | Stavros Sachtouris | |
126 | 02242022 | Stavros Sachtouris | ============== ========================= ======== ========== |
127 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
128 | 02242022 | Stavros Sachtouris | ============== ========================= ======== ========== |
129 | 02242022 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
130 | 02242022 | Stavros Sachtouris | ============== ========================= ======== ========== |
131 | 02242022 | Stavros Sachtouris | |
132 | 02242022 | Stavros Sachtouris | | |
133 | 02242022 | Stavros Sachtouris | |
134 | 3b1963eb | Stavros Sachtouris | ================= =================================== ======== ========== |
135 | 68386e00 | Stavros Sachtouris | Request Parameter Value Cyclades OS/Compute |
136 | 3b1963eb | Stavros Sachtouris | ================= =================================== ======== ========== |
137 | ea24170f | Stavros Sachtouris | json Respond in json default **✘** |
138 | ea24170f | Stavros Sachtouris | xml Respond in xml ✔ **✘** |
139 | 3b1963eb | Stavros Sachtouris | changes-since Servers delete since that timestamp ✔ ✔ |
140 | 3b1963eb | Stavros Sachtouris | image Image reference **✘** ✔ |
141 | 3b1963eb | Stavros Sachtouris | flavor VM flavor reference **✘** ✔ |
142 | 3b1963eb | Stavros Sachtouris | server Server flavor reference **✘** ✔ |
143 | 3b1963eb | Stavros Sachtouris | status Server status **✘** ✔ |
144 | 3b1963eb | Stavros Sachtouris | marker Last list last ID **✘** ✔ |
145 | 3b1963eb | Stavros Sachtouris | limit Page size **✘** ✔ |
146 | 3b1963eb | Stavros Sachtouris | ================= =================================== ======== ========== |
147 | 3b1963eb | Stavros Sachtouris | |
148 | a5ec880a | Stavros Sachtouris | * **json** and **xml** parameters are mutually exclusive. If none supported, |
149 | a5ec880a | Stavros Sachtouris | the response will be formated in json. |
150 | ea24170f | Stavros Sachtouris | |
151 | 4935e468 | Stavros Sachtouris | * **status** refers to the `server status <#status-ref>`_ |
152 | 4935e468 | Stavros Sachtouris | |
153 | ea24170f | Stavros Sachtouris | * **changes-since** must be an ISO8601 date string |
154 | ea24170f | Stavros Sachtouris | |
155 | 02242022 | Stavros Sachtouris | .. note:: Request body should be empty |
156 | 3b1963eb | Stavros Sachtouris | |
157 | 02242022 | Stavros Sachtouris | .. rubric:: Response |
158 | 3b1963eb | Stavros Sachtouris | |
159 | 3b1963eb | Stavros Sachtouris | =========================== ===================== |
160 | 3b1963eb | Stavros Sachtouris | Return Code Description |
161 | 3b1963eb | Stavros Sachtouris | =========================== ===================== |
162 | 3b1963eb | Stavros Sachtouris | 200 (OK) Request succeeded |
163 | 3b1963eb | Stavros Sachtouris | 304 (No servers since date) Can be returned if ``changes-since`` is given |
164 | 3b1963eb | Stavros Sachtouris | 400 (Bad Request) Invalid or malformed ``changes-since`` parameter |
165 | 3b1963eb | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
166 | ea24170f | Stavros Sachtouris | 403 (Forbidden) User is not allowed to perform this operation |
167 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
168 | e7f266c3 | Stavros Sachtouris | \ internal error |
169 | 3b1963eb | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
170 | 3b1963eb | Stavros Sachtouris | =========================== ===================== |
171 | 3b1963eb | Stavros Sachtouris | |
172 | 02242022 | Stavros Sachtouris | | |
173 | 02242022 | Stavros Sachtouris | |
174 | 02242022 | Stavros Sachtouris | Response body contents:: |
175 | 3b1963eb | Stavros Sachtouris | |
176 | 02242022 | Stavros Sachtouris | servers: [ |
177 | 02242022 | Stavros Sachtouris | { |
178 | 02242022 | Stavros Sachtouris | <server attribute>: <value>, |
179 | 02242022 | Stavros Sachtouris | ... |
180 | 02242022 | Stavros Sachtouris | }, ... |
181 | 02242022 | Stavros Sachtouris | ] |
182 | 0e214bbe | Stavros Sachtouris | |
183 | 0e214bbe | Stavros Sachtouris | ================= ====================== ======== ========== |
184 | 68386e00 | Stavros Sachtouris | Server Attributes Description Cyclades OS/Compute |
185 | 0e214bbe | Stavros Sachtouris | ================= ====================== ======== ========== |
186 | 0e214bbe | Stavros Sachtouris | id The server id ✔ ✔ |
187 | 0e214bbe | Stavros Sachtouris | name The server name ✔ ✔ |
188 | 0e214bbe | Stavros Sachtouris | hostId Server playground empty ✔ |
189 | 0e214bbe | Stavros Sachtouris | created Creation date ✔ ✔ |
190 | 0e214bbe | Stavros Sachtouris | updated Creation date ✔ ✔ |
191 | 0e214bbe | Stavros Sachtouris | flavorRef The flavor id ✔ **✘** |
192 | 0e214bbe | Stavros Sachtouris | flavor The flavor id **✘** ✔ |
193 | 0e214bbe | Stavros Sachtouris | imageRef The image id ✔ **✘** |
194 | 0e214bbe | Stavros Sachtouris | image The image id **✘** ✔ |
195 | 0e214bbe | Stavros Sachtouris | progress Build progress ✔ ✔ |
196 | 0e214bbe | Stavros Sachtouris | status Server status ✔ ✔ |
197 | 0e214bbe | Stavros Sachtouris | attachments Network interfaces ✔ **✘** |
198 | 0e214bbe | Stavros Sachtouris | addresses Network interfaces **✘** ✔ |
199 | 0e214bbe | Stavros Sachtouris | metadata Server custom metadata ✔ ✔ |
200 | 0e214bbe | Stavros Sachtouris | ================= ====================== ======== ========== |
201 | 3b1963eb | Stavros Sachtouris | |
202 | e31f6f23 | Stavros Sachtouris | * **hostId** is not used in Cyclades, but is returned as an empty string for |
203 | e31f6f23 | Stavros Sachtouris | compatibility |
204 | 3b1963eb | Stavros Sachtouris | |
205 | a5ec880a | Stavros Sachtouris | * **progress** is changing while the server is building up and has values |
206 | e31f6f23 | Stavros Sachtouris | between 0 and 100. When it reaches 100 the server is built. |
207 | 3b1963eb | Stavros Sachtouris | |
208 | 4935e468 | Stavros Sachtouris | * **status** refers to `the status <#status-ref>`_ of the server |
209 | 3b1963eb | Stavros Sachtouris | |
210 | a5ec880a | Stavros Sachtouris | * **metadata** are custom key:value pairs used to specify various attributes of |
211 | e31f6f23 | Stavros Sachtouris | the VM (e.g. OS, super user, etc.) |
212 | 3b1963eb | Stavros Sachtouris | |
213 | a5ec880a | Stavros Sachtouris | * **attachments** in Cyclades are lists of network interfaces (nics). |
214 | 68386e00 | Stavros Sachtouris | **Attachments** are different to OS/Compute's **addresses**. The former is a |
215 | e31f6f23 | Stavros Sachtouris | list of the server's `network interface connections <#nic-ref>`_ while the |
216 | e31f6f23 | Stavros Sachtouris | later is just a list of networks. Thus, a Cyclades virtual server may be |
217 | e31f6f23 | Stavros Sachtouris | connected to the same network through more than one distinct network |
218 | e31f6f23 | Stavros Sachtouris | interfaces (e.g. server 43 is connected to network 101 with nic-43-1 and |
219 | e31f6f23 | Stavros Sachtouris | nic-43-2 in the example bellow). |
220 | 3b1963eb | Stavros Sachtouris | |
221 | a5ec880a | Stavros Sachtouris | * **Network Interfaces (NICs)** contain information about a server's connection |
222 | e31f6f23 | Stavros Sachtouris | to a network. Each NIC is identified by an id of the form |
223 | e31f6f23 | Stavros Sachtouris | nic-<server-id>-<ordinal-number>. More details can be found `here |
224 | e31f6f23 | Stavros Sachtouris | <#nic-ref>`_. |
225 | 2cd1c00a | Giorgos Verigakis | |
226 | 634ef3a8 | Stavros Sachtouris | *Example List Servers: JSON* |
227 | c3945370 | Vangelis Koukis | |
228 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
229 | 2cd1c00a | Giorgos Verigakis | |
230 | 2cd1c00a | Giorgos Verigakis | { |
231 | 68386e00 | Stavros Sachtouris | "servers": |
232 | 68386e00 | Stavros Sachtouris | {"values": [ |
233 | e31f6f23 | Stavros Sachtouris | { |
234 | 68386e00 | Stavros Sachtouris | "attachments": { |
235 | 68386e00 | Stavros Sachtouris | "values": [ |
236 | 2cd1c00a | Giorgos Verigakis | { |
237 | 68386e00 | Stavros Sachtouris | "id": "nic-42-0", |
238 | 68386e00 | Stavros Sachtouris | "network_id": "101", |
239 | 68386e00 | Stavros Sachtouris | "mac_address": "aa:00:00:49:2e:7e", |
240 | 68386e00 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
241 | 68386e00 | Stavros Sachtouris | "ipv4": "192.168.4.5", |
242 | 68386e00 | Stavros Sachtouris | "ipv6": "2001:648:2ffc:1222:a800:ff:fef5:3f5b" |
243 | e31f6f23 | Stavros Sachtouris | } |
244 | e31f6f23 | Stavros Sachtouris | ] |
245 | e31f6f23 | Stavros Sachtouris | }, |
246 | 68386e00 | Stavros Sachtouris | "created': '2011-04-19T10:18:52.085737+00:00', |
247 | 68386e00 | Stavros Sachtouris | "flavorRef": "1", |
248 | 68386e00 | Stavros Sachtouris | "hostId": "", |
249 | 68386e00 | Stavros Sachtouris | "id": "42", |
250 | 68386e00 | Stavros Sachtouris | "imageRef": "3", |
251 | 68386e00 | Stavros Sachtouris | "metadata": {"values": {"foo": "bar"}}, |
252 | 68386e00 | Stavros Sachtouris | "name": "My Server", |
253 | 68386e00 | Stavros Sachtouris | "status": "ACTIVE", |
254 | 68386e00 | Stavros Sachtouris | "updated": "2011-05-29T14:07:07.037602+00:00" |
255 | e31f6f23 | Stavros Sachtouris | }, { |
256 | 68386e00 | Stavros Sachtouris | "attachments": { |
257 | 68386e00 | Stavros Sachtouris | "values": [ |
258 | 2cd1c00a | Giorgos Verigakis | { |
259 | 68386e00 | Stavros Sachtouris | "id": "nic-43-0", |
260 | 68386e00 | Stavros Sachtouris | "mac_address": "aa:00:00:91:2f:df", |
261 | 68386e00 | Stavros Sachtouris | "network_id": "1", |
262 | 68386e00 | Stavros Sachtouris | "ipv4": "192.168.32.2" |
263 | e31f6f23 | Stavros Sachtouris | }, { |
264 | 68386e00 | Stavros Sachtouris | "id": "nic-43-1", |
265 | 68386e00 | Stavros Sachtouris | "network_id": "101", |
266 | 68386e00 | Stavros Sachtouris | "mac_address": "aa:00:00:49:2g:7f", |
267 | 68386e00 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
268 | 68386e00 | Stavros Sachtouris | "ipv4": "192.168.32.6", |
269 | 68386e00 | Stavros Sachtouris | "ipv6": "2001:648:2ffc:1222:a800:ff:fef5:3f5c' |
270 | e31f6f23 | Stavros Sachtouris | }, { |
271 | 68386e00 | Stavros Sachtouris | "id": "nic-43-2", |
272 | 68386e00 | Stavros Sachtouris | "network_id": "101", |
273 | 68386e00 | Stavros Sachtouris | "mac_address": "aa:00:00:51:2h:7f", |
274 | 68386e00 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
275 | 68386e00 | Stavros Sachtouris | "ipv4": "192.168.32.7", |
276 | 68386e00 | Stavros Sachtouris | "ipv6": "2001:638:2eec:1222:a800:ff:fef5:3f5c" |
277 | 2cd1c00a | Giorgos Verigakis | } |
278 | e31f6f23 | Stavros Sachtouris | ] |
279 | e31f6f23 | Stavros Sachtouris | }, |
280 | 68386e00 | Stavros Sachtouris | "created": "2011-05-02T20:51:08.527759+00:00", |
281 | 68386e00 | Stavros Sachtouris | "flavorRef": "1", |
282 | 68386e00 | Stavros Sachtouris | "hostId": "", |
283 | 68386e00 | Stavros Sachtouris | "id": "43", |
284 | 68386e00 | Stavros Sachtouris | "imageRef": "3", |
285 | 68386e00 | Stavros Sachtouris | "name": "Other Server", |
286 | 68386e00 | Stavros Sachtouris | "description": "A sample server to showcase server requests", |
287 | 68386e00 | Stavros Sachtouris | "progress": "0", |
288 | 68386e00 | Stavros Sachtouris | "status": "ACTIVE", |
289 | 68386e00 | Stavros Sachtouris | "updated": "2011-05-29T14:59:11.267087+00:00" |
290 | e31f6f23 | Stavros Sachtouris | } |
291 | e31f6f23 | Stavros Sachtouris | ] |
292 | e31f6f23 | Stavros Sachtouris | } |
293 | 2cd1c00a | Giorgos Verigakis | } |
294 | 2cd1c00a | Giorgos Verigakis | |
295 | 2cd1c00a | Giorgos Verigakis | |
296 | 0e214bbe | Stavros Sachtouris | Create Server |
297 | 0e214bbe | Stavros Sachtouris | ............. |
298 | 0e214bbe | Stavros Sachtouris | |
299 | 68386e00 | Stavros Sachtouris | Create a new virtual server |
300 | 68386e00 | Stavros Sachtouris | |
301 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
302 | 68386e00 | Stavros Sachtouris | |
303 | e31f6f23 | Stavros Sachtouris | ============ ====== ======== ========== |
304 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
305 | e31f6f23 | Stavros Sachtouris | ============ ====== ======== ========== |
306 | e31f6f23 | Stavros Sachtouris | ``/servers`` POST ✔ ✔ |
307 | e31f6f23 | Stavros Sachtouris | ============ ====== ======== ========== |
308 | 0e214bbe | Stavros Sachtouris | |
309 | 0e214bbe | Stavros Sachtouris | | |
310 | 0e214bbe | Stavros Sachtouris | |
311 | 68386e00 | Stavros Sachtouris | ============== ========================= ======== ========== |
312 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
313 | 68386e00 | Stavros Sachtouris | ============== ========================= ======== ========== |
314 | 68386e00 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
315 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
316 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
317 | 68386e00 | Stavros Sachtouris | ============== ========================= ======== ========== |
318 | 68386e00 | Stavros Sachtouris | |
319 | 634ef3a8 | Stavros Sachtouris | *Example Request Headers*:: |
320 | 634ef3a8 | Stavros Sachtouris | |
321 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
322 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
323 | 634ef3a8 | Stavros Sachtouris | Content-Length: 735 |
324 | 634ef3a8 | Stavros Sachtouris | |
325 | 68386e00 | Stavros Sachtouris | | |
326 | 68386e00 | Stavros Sachtouris | |
327 | 0e214bbe | Stavros Sachtouris | ================= =============== |
328 | 3458183d | Constantinos Venetsanopoulos | Request Parameter Value |
329 | 0e214bbe | Stavros Sachtouris | ================= =============== |
330 | 0e214bbe | Stavros Sachtouris | json Respond in json |
331 | 3458183d | Constantinos Venetsanopoulos | xml Respond in xml |
332 | 0e214bbe | Stavros Sachtouris | ================= =============== |
333 | 0e214bbe | Stavros Sachtouris | |
334 | 68386e00 | Stavros Sachtouris | Request body contents:: |
335 | 0e214bbe | Stavros Sachtouris | |
336 | 68386e00 | Stavros Sachtouris | server: { |
337 | 68386e00 | Stavros Sachtouris | <server attribute>: <value>, |
338 | 68386e00 | Stavros Sachtouris | ... |
339 | 68386e00 | Stavros Sachtouris | personality: [ |
340 | 68386e00 | Stavros Sachtouris | { |
341 | 68386e00 | Stavros Sachtouris | <personality attribute>: <value>, |
342 | 68386e00 | Stavros Sachtouris | ... |
343 | 68386e00 | Stavros Sachtouris | }, |
344 | 68386e00 | Stavros Sachtouris | ... |
345 | 68386e00 | Stavros Sachtouris | ], |
346 | 68386e00 | Stavros Sachtouris | ... |
347 | 68386e00 | Stavros Sachtouris | } |
348 | 0e214bbe | Stavros Sachtouris | |
349 | 0e214bbe | Stavros Sachtouris | =========== ==================== ======== ========== |
350 | 68386e00 | Stavros Sachtouris | Attributes Description Cyclades OS/Compute |
351 | 0e214bbe | Stavros Sachtouris | =========== ==================== ======== ========== |
352 | 0e214bbe | Stavros Sachtouris | name The server name ✔ ✔ |
353 | 0e214bbe | Stavros Sachtouris | imageRef Image id ✔ ✔ |
354 | 0e214bbe | Stavros Sachtouris | flavorRef Resources flavor ✔ ✔ |
355 | 0e214bbe | Stavros Sachtouris | personality Personality contents ✔ ✔ |
356 | 0e214bbe | Stavros Sachtouris | metadata Custom metadata ✔ ✔ |
357 | 0e214bbe | Stavros Sachtouris | =========== ==================== ======== ========== |
358 | 0e214bbe | Stavros Sachtouris | |
359 | 0e214bbe | Stavros Sachtouris | * **name** can be any string |
360 | 0e214bbe | Stavros Sachtouris | |
361 | a5ec880a | Stavros Sachtouris | * **imageRed** and **flavorRed** should refer to existing images and hardware |
362 | e31f6f23 | Stavros Sachtouris | flavors accessible by the user |
363 | 0e214bbe | Stavros Sachtouris | |
364 | e31f6f23 | Stavros Sachtouris | * **metadata** are ``key``:``value`` pairs of custom server-specific metadata. |
365 | e31f6f23 | Stavros Sachtouris | There are no semantic limitations. |
366 | 0e214bbe | Stavros Sachtouris | |
367 | e31f6f23 | Stavros Sachtouris | * **personality** (optional) is a list of personality injections. A personality |
368 | e31f6f23 | Stavros Sachtouris | injection is a small set of changes to a virtual server. Each change modifies |
369 | e31f6f23 | Stavros Sachtouris | a file on the virtual server, by injecting some data in it. The injected data |
370 | e31f6f23 | Stavros Sachtouris | (``contents``) should exceed 10240 *bytes* in size and must be base64 |
371 | 634ef3a8 | Stavros Sachtouris | encoded. A personality injection contains the following attributes: |
372 | 0e214bbe | Stavros Sachtouris | |
373 | 68386e00 | Stavros Sachtouris | ====================== =================== ======== ========== |
374 | 68386e00 | Stavros Sachtouris | Personality Attributes Description Cyclades OS/Compute |
375 | 68386e00 | Stavros Sachtouris | ====================== =================== ======== ========== |
376 | 68386e00 | Stavros Sachtouris | path File path on server ✔ ✔ |
377 | 68386e00 | Stavros Sachtouris | contents Data to inject ✔ ✔ |
378 | 68386e00 | Stavros Sachtouris | group User group ✔ **✘** |
379 | 68386e00 | Stavros Sachtouris | mode File access mode ✔ **✘** |
380 | 68386e00 | Stavros Sachtouris | owner File owner ✔ **✘** |
381 | 68386e00 | Stavros Sachtouris | ====================== =================== ======== ========== |
382 | 0e214bbe | Stavros Sachtouris | |
383 | 634ef3a8 | Stavros Sachtouris | *Example Create Server Request: JSON* |
384 | 634ef3a8 | Stavros Sachtouris | |
385 | 634ef3a8 | Stavros Sachtouris | .. code-block:: javascript |
386 | 634ef3a8 | Stavros Sachtouris | |
387 | 634ef3a8 | Stavros Sachtouris | { |
388 | 634ef3a8 | Stavros Sachtouris | "server": { |
389 | 634ef3a8 | Stavros Sachtouris | "name": "My Server Name: Example Name", |
390 | 634ef3a8 | Stavros Sachtouris | "imageRef": "da7a211f-...-f901ce81a3e6", |
391 | 634ef3a8 | Stavros Sachtouris | "flavorRef": 289, |
392 | 634ef3a8 | Stavros Sachtouris | "personality": [ |
393 | 634ef3a8 | Stavros Sachtouris | { |
394 | 634ef3a8 | Stavros Sachtouris | "path": "/Users/myusername/personlities/example1.file", |
395 | 634ef3a8 | Stavros Sachtouris | "contents": "some data to inject", |
396 | 634ef3a8 | Stavros Sachtouris | "group": "remotely-set user group", |
397 | 634ef3a8 | Stavros Sachtouris | "mode": "rw", |
398 | 634ef3a8 | Stavros Sachtouris | "owner": "ausername" |
399 | 634ef3a8 | Stavros Sachtouris | }, { |
400 | 634ef3a8 | Stavros Sachtouris | "path": "/Users/myusername/personlities/example2.file", |
401 | 634ef3a8 | Stavros Sachtouris | "contents": "some more data to inject", |
402 | 634ef3a8 | Stavros Sachtouris | "group": "", |
403 | 634ef3a8 | Stavros Sachtouris | "mode": "r", |
404 | 634ef3a8 | Stavros Sachtouris | "owner": "anotherusername" |
405 | 634ef3a8 | Stavros Sachtouris | } |
406 | 634ef3a8 | Stavros Sachtouris | ], |
407 | 634ef3a8 | Stavros Sachtouris | "metadata": { |
408 | 634ef3a8 | Stavros Sachtouris | "values": { |
409 | 634ef3a8 | Stavros Sachtouris | "EloquentDescription": "Example server with personality", |
410 | 634ef3a8 | Stavros Sachtouris | "ShortDescription": "Trying VMs" |
411 | 634ef3a8 | Stavros Sachtouris | } |
412 | 634ef3a8 | Stavros Sachtouris | } |
413 | 634ef3a8 | Stavros Sachtouris | } |
414 | 634ef3a8 | Stavros Sachtouris | } |
415 | 0e214bbe | Stavros Sachtouris | |
416 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
417 | 68386e00 | Stavros Sachtouris | |
418 | 0e214bbe | Stavros Sachtouris | =========================== ===================== |
419 | 0e214bbe | Stavros Sachtouris | Return Code Description |
420 | 0e214bbe | Stavros Sachtouris | =========================== ===================== |
421 | 0e214bbe | Stavros Sachtouris | 200 (OK) Request succeeded |
422 | 0e214bbe | Stavros Sachtouris | 400 (Bad Request) Malformed request data |
423 | 0e214bbe | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
424 | 0e214bbe | Stavros Sachtouris | 403 (Forbidden) User is not allowed to perform this operation |
425 | 0e214bbe | Stavros Sachtouris | 404 (Not Found) Image or Flavor not found |
426 | a5ec880a | Stavros Sachtouris | 413 (Over Limit) Exceeded some resource limit (#VMs, personality |
427 | 3458183d | Constantinos Venetsanopoulos | size, etc.) |
428 | 0e214bbe | Stavros Sachtouris | 415 (Bad Media Type) |
429 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
430 | e7f266c3 | Stavros Sachtouris | \ internal error |
431 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) No available backends or service currently |
432 | e7f266c3 | Stavros Sachtouris | \ unavailable |
433 | 0e214bbe | Stavros Sachtouris | =========================== ===================== |
434 | 0e214bbe | Stavros Sachtouris | |
435 | 0e214bbe | Stavros Sachtouris | | |
436 | 0e214bbe | Stavros Sachtouris | |
437 | 68386e00 | Stavros Sachtouris | Response body contents:: |
438 | 68386e00 | Stavros Sachtouris | |
439 | 68386e00 | Stavros Sachtouris | server: { |
440 | 68386e00 | Stavros Sachtouris | <server attribute>: <value>, |
441 | 68386e00 | Stavros Sachtouris | ... |
442 | 68386e00 | Stavros Sachtouris | } |
443 | 68386e00 | Stavros Sachtouris | |
444 | 68386e00 | Stavros Sachtouris | Server attributes are `listed here <#server-ref>`_. |
445 | 0e214bbe | Stavros Sachtouris | |
446 | 634ef3a8 | Stavros Sachtouris | *Example Create Server Response: JSON* |
447 | 68386e00 | Stavros Sachtouris | |
448 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
449 | 0e214bbe | Stavros Sachtouris | |
450 | e31f6f23 | Stavros Sachtouris | { |
451 | e31f6f23 | Stavros Sachtouris | "server": { |
452 | e31f6f23 | Stavros Sachtouris | "id": 28130 |
453 | e31f6f23 | Stavros Sachtouris | "status": "BUILD", |
454 | e31f6f23 | Stavros Sachtouris | "updated": "2013-04-10T13:52:18.140686+00:00", |
455 | e31f6f23 | Stavros Sachtouris | "hostId": "", |
456 | e31f6f23 | Stavros Sachtouris | "name": "My Server Name: Example Name", |
457 | e31f6f23 | Stavros Sachtouris | "imageRef": "da7a211f-...-f901ce81a3e6", |
458 | e31f6f23 | Stavros Sachtouris | "created": "2013-04-10T13:52:17.085402+00:00", |
459 | e31f6f23 | Stavros Sachtouris | "flavorRef": 289, |
460 | e31f6f23 | Stavros Sachtouris | "adminPass": "fKCqlZe2at", |
461 | e31f6f23 | Stavros Sachtouris | "suspended": false, |
462 | 68386e00 | Stavros Sachtouris | "progress": 0 |
463 | 634ef3a8 | Stavros Sachtouris | "metadata": { |
464 | 634ef3a8 | Stavros Sachtouris | "values": { |
465 | 634ef3a8 | Stavros Sachtouris | "EloquentDescription": "Example server with personality", |
466 | 634ef3a8 | Stavros Sachtouris | "ShortDescription": "Trying VMs" |
467 | 634ef3a8 | Stavros Sachtouris | } |
468 | 634ef3a8 | Stavros Sachtouris | } |
469 | e31f6f23 | Stavros Sachtouris | } |
470 | e31f6f23 | Stavros Sachtouris | } |
471 | 0e214bbe | Stavros Sachtouris | |
472 | 634ef3a8 | Stavros Sachtouris | *Example Create Server Response: XML* |
473 | 68386e00 | Stavros Sachtouris | |
474 | 68386e00 | Stavros Sachtouris | .. code-block:: xml |
475 | 68386e00 | Stavros Sachtouris | |
476 | 68386e00 | Stavros Sachtouris | <?xml version="1.0" encoding="UTF-8"?> |
477 | 68386e00 | Stavros Sachtouris | <server xmlns="http://docs.openstack.org/compute/api/v1.1"\ |
478 | 68386e00 | Stavros Sachtouris | xmlns:atom="http://www.w3.org/2005/Atom" |
479 | 68386e00 | Stavros Sachtouris | id="1" |
480 | 68386e00 | Stavros Sachtouris | status="BUILD" |
481 | 68386e00 | Stavros Sachtouris | hostId="", |
482 | 68386e00 | Stavros Sachtouris | name="My Server Name: Example Name" |
483 | 68386e00 | Stavros Sachtouris | imageRef="da7a211f-...-f901ce81a3e6" |
484 | 68386e00 | Stavros Sachtouris | created="2013-04-10T13:52:17.085402+00:00" |
485 | 68386e00 | Stavros Sachtouris | flavorRef="289" |
486 | 68386e00 | Stavros Sachtouris | adminPass="fKCqlZe2at" |
487 | 68386e00 | Stavros Sachtouris | suspended="false" |
488 | 68386e00 | Stavros Sachtouris | progress="0" |
489 | 68386e00 | Stavros Sachtouris | /> |
490 | 68386e00 | Stavros Sachtouris | |
491 | 2cd1c00a | Giorgos Verigakis | Get Server Stats |
492 | 2cd1c00a | Giorgos Verigakis | ................ |
493 | 2cd1c00a | Giorgos Verigakis | |
494 | 68386e00 | Stavros Sachtouris | .. note:: This operation is not part of OS/Compute v2. |
495 | 68386e00 | Stavros Sachtouris | |
496 | 68386e00 | Stavros Sachtouris | This operation returns URLs of graphs showing CPU and Network statistics. |
497 | 671d6f05 | Stavros Sachtouris | |
498 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
499 | 2cd1c00a | Giorgos Verigakis | |
500 | ea24170f | Stavros Sachtouris | ============================== ====== ======== ========== |
501 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
502 | ea24170f | Stavros Sachtouris | ============================== ====== ======== ========== |
503 | ea24170f | Stavros Sachtouris | ``/servers/<server-id>/stats`` GET ✔ **✘** |
504 | ea24170f | Stavros Sachtouris | ============================== ====== ======== ========== |
505 | 2cd1c00a | Giorgos Verigakis | |
506 | ea24170f | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
507 | 2cd1c00a | Giorgos Verigakis | |
508 | ea24170f | Stavros Sachtouris | | |
509 | ea24170f | Stavros Sachtouris | |
510 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
511 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
512 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
513 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
514 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
515 | ea24170f | Stavros Sachtouris | |
516 | ea24170f | Stavros Sachtouris | | |
517 | ea24170f | Stavros Sachtouris | |
518 | ea24170f | Stavros Sachtouris | ================= =============== |
519 | ea24170f | Stavros Sachtouris | Request Parameter Value |
520 | ea24170f | Stavros Sachtouris | ================= =============== |
521 | ea24170f | Stavros Sachtouris | json Respond in json |
522 | ea24170f | Stavros Sachtouris | xml Respond in xml |
523 | ea24170f | Stavros Sachtouris | ================= =============== |
524 | ea24170f | Stavros Sachtouris | |
525 | a5ec880a | Stavros Sachtouris | * **json** and **xml** parameters are mutually exclusive. If none supported, |
526 | a5ec880a | Stavros Sachtouris | the response will be formated in json. |
527 | ea24170f | Stavros Sachtouris | |
528 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
529 | 68386e00 | Stavros Sachtouris | |
530 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
531 | ea24170f | Stavros Sachtouris | |
532 | ea24170f | Stavros Sachtouris | =========================== ===================== |
533 | ea24170f | Stavros Sachtouris | Return Code Description |
534 | ea24170f | Stavros Sachtouris | =========================== ===================== |
535 | ea24170f | Stavros Sachtouris | 200 (OK) Request succeeded |
536 | ea24170f | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Server deleted |
537 | ea24170f | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
538 | ea24170f | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
539 | ea24170f | Stavros Sachtouris | 404 (Not Found) Server not found |
540 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
541 | e7f266c3 | Stavros Sachtouris | \ internal error |
542 | ea24170f | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
543 | ea24170f | Stavros Sachtouris | =========================== ===================== |
544 | ea24170f | Stavros Sachtouris | |
545 | ea24170f | Stavros Sachtouris | | |
546 | 2cd1c00a | Giorgos Verigakis | |
547 | 68386e00 | Stavros Sachtouris | Response body contents:: |
548 | 68386e00 | Stavros Sachtouris | |
549 | 68386e00 | Stavros Sachtouris | stats: {<parameter>: <value> } |
550 | 68386e00 | Stavros Sachtouris | |
551 | 68386e00 | Stavros Sachtouris | ============= ====================== |
552 | 3458183d | Constantinos Venetsanopoulos | Parameter Description |
553 | 68386e00 | Stavros Sachtouris | ============= ====================== |
554 | 68386e00 | Stavros Sachtouris | serverRef Server ID |
555 | 68386e00 | Stavros Sachtouris | refresh Refresh frequency |
556 | 68386e00 | Stavros Sachtouris | cpuBar Latest CPU load graph URL |
557 | 68386e00 | Stavros Sachtouris | cpuTimeSeries CPU load / time graph URL |
558 | 68386e00 | Stavros Sachtouris | netBar Latest Network load graph URL |
559 | 68386e00 | Stavros Sachtouris | netTimeSeries Network load / time graph URL |
560 | 68386e00 | Stavros Sachtouris | ============= ====================== |
561 | 68386e00 | Stavros Sachtouris | |
562 | 68386e00 | Stavros Sachtouris | * **refresh** is the recommended sampling rate |
563 | 2cd1c00a | Giorgos Verigakis | |
564 | 634ef3a8 | Stavros Sachtouris | *Example Get Server Stats Response: JSON* |
565 | c3945370 | Vangelis Koukis | |
566 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
567 | 2cd1c00a | Giorgos Verigakis | |
568 | 2cd1c00a | Giorgos Verigakis | { |
569 | e31f6f23 | Stavros Sachtouris | "stats": { |
570 | e31f6f23 | Stavros Sachtouris | "serverRef": 1, |
571 | e31f6f23 | Stavros Sachtouris | "refresh": 60, |
572 | e31f6f23 | Stavros Sachtouris | "cpuBar": "http://stats.okeanos.grnet.gr/b9a...048c/cpu-bar.png", |
573 | e31f6f23 | Stavros Sachtouris | "cpuTimeSeries": "http://stats.okeanos.grnet.gr/b9a...048c/cpu-ts.png", |
574 | e31f6f23 | Stavros Sachtouris | "netBar": "http://stats.okeanos.grnet.gr/b9a...048c/net-bar.png", |
575 | e31f6f23 | Stavros Sachtouris | "netTimeSeries": "http://stats.okeanos.grnet.gr/b9a...048c/net-ts.png" |
576 | e31f6f23 | Stavros Sachtouris | } |
577 | 2cd1c00a | Giorgos Verigakis | } |
578 | 2cd1c00a | Giorgos Verigakis | |
579 | 634ef3a8 | Stavros Sachtouris | *Example Get Network Details Response: XML* |
580 | c3945370 | Vangelis Koukis | |
581 | c3945370 | Vangelis Koukis | .. code-block:: xml |
582 | 2cd1c00a | Giorgos Verigakis | |
583 | 2cd1c00a | Giorgos Verigakis | <?xml version="1.0" encoding="UTF-8"?> |
584 | a5ec880a | Stavros Sachtouris | <stats xmlns="http://docs.openstack.org/compute/api/v1.1"\ |
585 | 671d6f05 | Stavros Sachtouris | xmlns:atom="http://www.w3.org/2005/Atom" |
586 | 671d6f05 | Stavros Sachtouris | serverRef="1" |
587 | 671d6f05 | Stavros Sachtouris | refresh="60" |
588 | 671d6f05 | Stavros Sachtouris | cpuBar="https://www.example.com/stats/snf-42/cpu-bar/", |
589 | 671d6f05 | Stavros Sachtouris | netTimeSeries="https://example.com/stats/snf-42/net-ts/", |
590 | 671d6f05 | Stavros Sachtouris | netBar="https://example.com/stats/snf-42/net-bar/", |
591 | 671d6f05 | Stavros Sachtouris | cpuTimeSeries="https://www.example.com/stats/snf-42/cpu-ts/" |
592 | 2cd1c00a | Giorgos Verigakis | </stats> |
593 | 2cd1c00a | Giorgos Verigakis | |
594 | 671d6f05 | Stavros Sachtouris | Get Server Diagnostics |
595 | 671d6f05 | Stavros Sachtouris | ...................... |
596 | 671d6f05 | Stavros Sachtouris | |
597 | 68386e00 | Stavros Sachtouris | .. note:: This operation is not part of OS/Compute v2. |
598 | 671d6f05 | Stavros Sachtouris | |
599 | 68386e00 | Stavros Sachtouris | This operation returns diagnostic information (logs) for a server. |
600 | 68386e00 | Stavros Sachtouris | |
601 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
602 | 671d6f05 | Stavros Sachtouris | |
603 | 671d6f05 | Stavros Sachtouris | ==================================== ====== ======== ========== |
604 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
605 | 671d6f05 | Stavros Sachtouris | ==================================== ====== ======== ========== |
606 | 671d6f05 | Stavros Sachtouris | ``/servers/<server-id>/diagnostics`` GET ✔ **✘** |
607 | 671d6f05 | Stavros Sachtouris | ==================================== ====== ======== ========== |
608 | 671d6f05 | Stavros Sachtouris | |
609 | 671d6f05 | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
610 | 671d6f05 | Stavros Sachtouris | |
611 | 671d6f05 | Stavros Sachtouris | | |
612 | 671d6f05 | Stavros Sachtouris | |
613 | 8a86499c | Stavros Sachtouris | ============== ========================= ======== ========== |
614 | 8a86499c | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
615 | 8a86499c | Stavros Sachtouris | ============== ========================= ======== ========== |
616 | 8a86499c | Stavros Sachtouris | X-Auth-Token User authentication token required required |
617 | 8a86499c | Stavros Sachtouris | ============== ========================= ======== ========== |
618 | 671d6f05 | Stavros Sachtouris | |
619 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
620 | 68386e00 | Stavros Sachtouris | |
621 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
622 | 68386e00 | Stavros Sachtouris | |
623 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
624 | 671d6f05 | Stavros Sachtouris | |
625 | 671d6f05 | Stavros Sachtouris | =========================== ===================== |
626 | 671d6f05 | Stavros Sachtouris | Return Code Description |
627 | 671d6f05 | Stavros Sachtouris | =========================== ===================== |
628 | 671d6f05 | Stavros Sachtouris | 200 (OK) Request succeeded |
629 | 671d6f05 | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Server deleted |
630 | 671d6f05 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
631 | 671d6f05 | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
632 | 671d6f05 | Stavros Sachtouris | 404 (Not Found) Server not found |
633 | 671d6f05 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
634 | e7f266c3 | Stavros Sachtouris | \ internal error |
635 | 671d6f05 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
636 | 671d6f05 | Stavros Sachtouris | =========================== ===================== |
637 | 671d6f05 | Stavros Sachtouris | |
638 | 68386e00 | Stavros Sachtouris | | |
639 | 68386e00 | Stavros Sachtouris | |
640 | 68386e00 | Stavros Sachtouris | Response body contents:: |
641 | 68386e00 | Stavros Sachtouris | |
642 | 68386e00 | Stavros Sachtouris | [ |
643 | 68386e00 | Stavros Sachtouris | { |
644 | 68386e00 | Stavros Sachtouris | <diagnostic attribute}: <value>, |
645 | 68386e00 | Stavros Sachtouris | ... |
646 | 68386e00 | Stavros Sachtouris | }, { |
647 | 68386e00 | Stavros Sachtouris | <diagnostic attribute}: <value>, |
648 | 68386e00 | Stavros Sachtouris | ... |
649 | 68386e00 | Stavros Sachtouris | }, |
650 | 68386e00 | Stavros Sachtouris | ... |
651 | 68386e00 | Stavros Sachtouris | ] |
652 | 671d6f05 | Stavros Sachtouris | |
653 | 671d6f05 | Stavros Sachtouris | ==================== =========== |
654 | 671d6f05 | Stavros Sachtouris | Diagnostic attribute Description |
655 | 671d6f05 | Stavros Sachtouris | ==================== =========== |
656 | 671d6f05 | Stavros Sachtouris | level Debug level |
657 | 671d6f05 | Stavros Sachtouris | created Log entry timestamp |
658 | 671d6f05 | Stavros Sachtouris | source Log source proccess |
659 | 3458183d | Constantinos Venetsanopoulos | source_date Log source date |
660 | 671d6f05 | Stavros Sachtouris | message Log description |
661 | 671d6f05 | Stavros Sachtouris | details Detailed log description |
662 | 671d6f05 | Stavros Sachtouris | ==================== =========== |
663 | 671d6f05 | Stavros Sachtouris | |
664 | 634ef3a8 | Stavros Sachtouris | *Example Get Server Diagnostics Response: JSON* |
665 | 671d6f05 | Stavros Sachtouris | |
666 | 671d6f05 | Stavros Sachtouris | .. code-block:: javascript |
667 | 671d6f05 | Stavros Sachtouris | |
668 | 671d6f05 | Stavros Sachtouris | [ |
669 | 671d6f05 | Stavros Sachtouris | { |
670 | 671d6f05 | Stavros Sachtouris | "level": "DEBUG", |
671 | 671d6f05 | Stavros Sachtouris | "created": "2013-04-09T15:25:53.965144+00:00", |
672 | 671d6f05 | Stavros Sachtouris | "source": "image-helper-task-start", |
673 | 671d6f05 | Stavros Sachtouris | "source_date": "2013-04-09T15:25:53.954695+00:00", |
674 | 671d6f05 | Stavros Sachtouris | "message": "FixPartitionTable", |
675 | 671d6f05 | Stavros Sachtouris | "details": null |
676 | 671d6f05 | Stavros Sachtouris | }, { |
677 | 671d6f05 | Stavros Sachtouris | "level": "DEBUG", |
678 | 671d6f05 | Stavros Sachtouris | "created": "2013-04-09T15:25:46.413718+00:00", |
679 | 671d6f05 | Stavros Sachtouris | "source": "image-info", |
680 | 671d6f05 | Stavros Sachtouris | "source_date": "2013-04-09T15:25:46.404477+00:00", |
681 | 671d6f05 | Stavros Sachtouris | "message": "Starting customization VM...", |
682 | 671d6f05 | Stavros Sachtouris | "details": null |
683 | 671d6f05 | Stavros Sachtouris | }, { |
684 | 671d6f05 | Stavros Sachtouris | "level": "DEBUG", |
685 | 671d6f05 | Stavros Sachtouris | "created": "2013-04-09T15:25:46.207038+00:00", |
686 | 671d6f05 | Stavros Sachtouris | "source": "image-info", |
687 | 671d6f05 | Stavros Sachtouris | "source_date": "2013-04-09T15:25:46.197183+00:00", |
688 | 671d6f05 | Stavros Sachtouris | "message": "Image copy finished.", |
689 | 671d6f05 | Stavros Sachtouris | "details": "All operations finished as they should. No errors reported." |
690 | 671d6f05 | Stavros Sachtouris | } |
691 | 671d6f05 | Stavros Sachtouris | ] |
692 | 671d6f05 | Stavros Sachtouris | |
693 | cfdbd784 | Stavros Sachtouris | Get Server Details |
694 | cfdbd784 | Stavros Sachtouris | .................. |
695 | cfdbd784 | Stavros Sachtouris | |
696 | 68386e00 | Stavros Sachtouris | This operation returns detailed information for a virtual server |
697 | 68386e00 | Stavros Sachtouris | |
698 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
699 | 68386e00 | Stavros Sachtouris | |
700 | cfdbd784 | Stavros Sachtouris | ======================== ====== ======== ========== |
701 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
702 | cfdbd784 | Stavros Sachtouris | ======================== ====== ======== ========== |
703 | cfdbd784 | Stavros Sachtouris | ``/servers/<server id>`` GET ✔ ✔ |
704 | cfdbd784 | Stavros Sachtouris | ======================== ====== ======== ========== |
705 | cfdbd784 | Stavros Sachtouris | |
706 | cfdbd784 | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
707 | cfdbd784 | Stavros Sachtouris | |
708 | cfdbd784 | Stavros Sachtouris | | |
709 | cfdbd784 | Stavros Sachtouris | |
710 | cfdbd784 | Stavros Sachtouris | ============== ========================= ======== ========== |
711 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
712 | cfdbd784 | Stavros Sachtouris | ============== ========================= ======== ========== |
713 | cfdbd784 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
714 | cfdbd784 | Stavros Sachtouris | ============== ========================= ======== ========== |
715 | cfdbd784 | Stavros Sachtouris | |
716 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
717 | 68386e00 | Stavros Sachtouris | |
718 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
719 | 68386e00 | Stavros Sachtouris | |
720 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
721 | cfdbd784 | Stavros Sachtouris | |
722 | cfdbd784 | Stavros Sachtouris | =========================== ===================== |
723 | cfdbd784 | Stavros Sachtouris | Return Code Description |
724 | cfdbd784 | Stavros Sachtouris | =========================== ===================== |
725 | cfdbd784 | Stavros Sachtouris | 200 (OK) Request succeeded |
726 | cfdbd784 | Stavros Sachtouris | 400 (Bad Request) Malformed server id |
727 | cfdbd784 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
728 | cfdbd784 | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
729 | cfdbd784 | Stavros Sachtouris | 404 (Not Found) Server not found |
730 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
731 | e7f266c3 | Stavros Sachtouris | \ internal error |
732 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) No available backends or service currently |
733 | e7f266c3 | Stavros Sachtouris | \ unavailable |
734 | cfdbd784 | Stavros Sachtouris | =========================== ===================== |
735 | cfdbd784 | Stavros Sachtouris | |
736 | cfdbd784 | Stavros Sachtouris | | |
737 | cfdbd784 | Stavros Sachtouris | |
738 | 68386e00 | Stavros Sachtouris | Response body contents:: |
739 | 68386e00 | Stavros Sachtouris | |
740 | 68386e00 | Stavros Sachtouris | server: { |
741 | 68386e00 | Stavros Sachtouris | <server attribute>: <value>, |
742 | 68386e00 | Stavros Sachtouris | ... |
743 | 68386e00 | Stavros Sachtouris | } |
744 | cfdbd784 | Stavros Sachtouris | |
745 | cfdbd784 | Stavros Sachtouris | ================= ====================== ======== ========== |
746 | 68386e00 | Stavros Sachtouris | Server Attributes Description Cyclades OS/Compute |
747 | cfdbd784 | Stavros Sachtouris | ================= ====================== ======== ========== |
748 | cfdbd784 | Stavros Sachtouris | id The server id ✔ ✔ |
749 | cfdbd784 | Stavros Sachtouris | name The server name ✔ ✔ |
750 | cfdbd784 | Stavros Sachtouris | hostId Server playground empty ✔ |
751 | cfdbd784 | Stavros Sachtouris | created Creation date ✔ ✔ |
752 | cfdbd784 | Stavros Sachtouris | updated Creation date ✔ ✔ |
753 | cfdbd784 | Stavros Sachtouris | flavorRef The flavor id ✔ **✘** |
754 | cfdbd784 | Stavros Sachtouris | flavor The flavor id **✘** ✔ |
755 | cfdbd784 | Stavros Sachtouris | imageRef The image id ✔ **✘** |
756 | cfdbd784 | Stavros Sachtouris | image The image id **✘** ✔ |
757 | cfdbd784 | Stavros Sachtouris | progress Build progress ✔ ✔ |
758 | cfdbd784 | Stavros Sachtouris | status Server status ✔ ✔ |
759 | 0fbcb755 | Stavros Sachtouris | suspended If server is suspended ✔ **✘** |
760 | cfdbd784 | Stavros Sachtouris | attachments Network interfaces ✔ **✘** |
761 | cfdbd784 | Stavros Sachtouris | addresses Network interfaces **✘** ✔ |
762 | cfdbd784 | Stavros Sachtouris | metadata Server custom metadata ✔ ✔ |
763 | 0fbcb755 | Stavros Sachtouris | diagnostics Diagnostic information ✔ **✘** |
764 | cfdbd784 | Stavros Sachtouris | ================= ====================== ======== ========== |
765 | cfdbd784 | Stavros Sachtouris | |
766 | e31f6f23 | Stavros Sachtouris | * **hostId** is not used in Cyclades, but is returned as an empty string for |
767 | e31f6f23 | Stavros Sachtouris | compatibility |
768 | cfdbd784 | Stavros Sachtouris | |
769 | a5ec880a | Stavros Sachtouris | * **progress** is changing while the server is building up and has values |
770 | e31f6f23 | Stavros Sachtouris | between 0 and 100. When it reaches 100 the server is built. |
771 | cfdbd784 | Stavros Sachtouris | |
772 | de2e08f6 | Stavros Sachtouris | * **status** refers to `the status <#status-ref>`_ of the server |
773 | cfdbd784 | Stavros Sachtouris | |
774 | a5ec880a | Stavros Sachtouris | * **metadata** are custom key:value pairs used to specify various attributes of |
775 | e31f6f23 | Stavros Sachtouris | the VM (e.g. OS, super user, etc.) |
776 | cfdbd784 | Stavros Sachtouris | |
777 | a5ec880a | Stavros Sachtouris | * **attachments** in Cyclades are lists of network interfaces (NICs). |
778 | 68386e00 | Stavros Sachtouris | **Attachments** are different to OS/Compute's **addresses**. The former is a |
779 | e31f6f23 | Stavros Sachtouris | list of the server's `network interface connections <#nic-ref>`_ while the |
780 | e31f6f23 | Stavros Sachtouris | later is just a list of networks. Thus, a Cyclades virtual server may be |
781 | e31f6f23 | Stavros Sachtouris | connected to the same network through more than one distinct network |
782 | e31f6f23 | Stavros Sachtouris | interfaces. |
783 | cfdbd784 | Stavros Sachtouris | |
784 | a5ec880a | Stavros Sachtouris | * **diagnostics** is a list of items that contain key:value information useful |
785 | e31f6f23 | Stavros Sachtouris | for diagnosing the server behavior and may be used by the administrators of |
786 | e31f6f23 | Stavros Sachtouris | deployed Synnefo setups. |
787 | 0fbcb755 | Stavros Sachtouris | |
788 | 634ef3a8 | Stavros Sachtouris | *Example Details for server with id 42042: JSON* |
789 | cfdbd784 | Stavros Sachtouris | |
790 | cfdbd784 | Stavros Sachtouris | .. code-block:: javascript |
791 | cfdbd784 | Stavros Sachtouris | |
792 | cfdbd784 | Stavros Sachtouris | { |
793 | cfdbd784 | Stavros Sachtouris | "server": { |
794 | cfdbd784 | Stavros Sachtouris | "id": 42042, |
795 | cfdbd784 | Stavros Sachtouris | "name": "My Example Server", |
796 | cfdbd784 | Stavros Sachtouris | "status": "ACTIVE", |
797 | cfdbd784 | Stavros Sachtouris | "updated": "2013-04-18T10:09:57.824266+00:00", |
798 | cfdbd784 | Stavros Sachtouris | "hostId": "", |
799 | cfdbd784 | Stavros Sachtouris | "imageRef": "926a1bc5-2d85-49d4-aebe-0fc127ed89b9", |
800 | cfdbd784 | Stavros Sachtouris | "created": "2013-04-18T10:06:58.288273+00:00", |
801 | cfdbd784 | Stavros Sachtouris | "flavorRef": 22, |
802 | cfdbd784 | Stavros Sachtouris | "attachments": { |
803 | cfdbd784 | Stavros Sachtouris | "values": [{ |
804 | cfdbd784 | Stavros Sachtouris | "network_id": "1888", |
805 | cfdbd784 | Stavros Sachtouris | "mac_address": "aa:0c:f5:ad:16:41", |
806 | cfdbd784 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
807 | cfdbd784 | Stavros Sachtouris | "ipv4": "83.212.112.56", |
808 | cfdbd784 | Stavros Sachtouris | "ipv6": "2001:648:2ffc:1119:a80c:f5ff:fead:1641", |
809 | cfdbd784 | Stavros Sachtouris | "id": "nic-42042-0" |
810 | cfdbd784 | Stavros Sachtouris | }] |
811 | cfdbd784 | Stavros Sachtouris | }, |
812 | cfdbd784 | Stavros Sachtouris | "suspended": false, |
813 | cfdbd784 | Stavros Sachtouris | "diagnostics": [{ |
814 | cfdbd784 | Stavros Sachtouris | "level": "DEBUG", |
815 | cfdbd784 | Stavros Sachtouris | "created": "2013-04-18T10:09:52.776920+00:00", |
816 | cfdbd784 | Stavros Sachtouris | "source": "image-info", |
817 | cfdbd784 | Stavros Sachtouris | "source_date": "2013-04-18T10:09:52.709791+00:00", |
818 | cfdbd784 | Stavros Sachtouris | "message": "Image customization finished successfully.", |
819 | cfdbd784 | Stavros Sachtouris | "details": null |
820 | cfdbd784 | Stavros Sachtouris | }], |
821 | cfdbd784 | Stavros Sachtouris | "progress": 100, |
822 | cfdbd784 | Stavros Sachtouris | "metadata": { |
823 | cfdbd784 | Stavros Sachtouris | "values": {"OS": "windows", "users": "Administrator"} |
824 | cfdbd784 | Stavros Sachtouris | } |
825 | cfdbd784 | Stavros Sachtouris | } |
826 | cfdbd784 | Stavros Sachtouris | } |
827 | 2cd1c00a | Giorgos Verigakis | |
828 | 68386e00 | Stavros Sachtouris | .. note:: the ``values`` layer is not featured in OS/Compute API |
829 | 68386e00 | Stavros Sachtouris | |
830 | 0fbcb755 | Stavros Sachtouris | Rename Server |
831 | 0fbcb755 | Stavros Sachtouris | ............. |
832 | 0fbcb755 | Stavros Sachtouris | |
833 | 68386e00 | Stavros Sachtouris | Modify the ``name`` attribute of a virtual server. OS/Compute API also features |
834 | 68386e00 | Stavros Sachtouris | the modification of IP addresses |
835 | 68386e00 | Stavros Sachtouris | |
836 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
837 | 68386e00 | Stavros Sachtouris | |
838 | 0fbcb755 | Stavros Sachtouris | ======================== ====== ======== ========== |
839 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
840 | 0fbcb755 | Stavros Sachtouris | ======================== ====== ======== ========== |
841 | 0fbcb755 | Stavros Sachtouris | ``/servers/<server id>`` PUT ✔ ✔ |
842 | 0fbcb755 | Stavros Sachtouris | ======================== ====== ======== ========== |
843 | 0fbcb755 | Stavros Sachtouris | |
844 | 0fbcb755 | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
845 | 0fbcb755 | Stavros Sachtouris | |
846 | 0fbcb755 | Stavros Sachtouris | | |
847 | 0fbcb755 | Stavros Sachtouris | |
848 | 0fbcb755 | Stavros Sachtouris | ============== ========================= ======== ========== |
849 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
850 | 0fbcb755 | Stavros Sachtouris | ============== ========================= ======== ========== |
851 | 0fbcb755 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
852 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
853 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
854 | 0fbcb755 | Stavros Sachtouris | ============== ========================= ======== ========== |
855 | 0fbcb755 | Stavros Sachtouris | |
856 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
857 | 634ef3a8 | Stavros Sachtouris | |
858 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
859 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
860 | 634ef3a8 | Stavros Sachtouris | Content-Length: 54 |
861 | 634ef3a8 | Stavros Sachtouris | |
862 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
863 | 68386e00 | Stavros Sachtouris | |
864 | 68386e00 | Stavros Sachtouris | Request body contents:: |
865 | 68386e00 | Stavros Sachtouris | |
866 | 68386e00 | Stavros Sachtouris | server: { |
867 | 68386e00 | Stavros Sachtouris | <server attribute>: <value>, |
868 | 68386e00 | Stavros Sachtouris | ... |
869 | 68386e00 | Stavros Sachtouris | } |
870 | 0fbcb755 | Stavros Sachtouris | |
871 | 0fbcb755 | Stavros Sachtouris | =========== ==================== ======== ========== |
872 | 68386e00 | Stavros Sachtouris | Attribute Description Cyclades OS/Compute |
873 | 0fbcb755 | Stavros Sachtouris | =========== ==================== ======== ========== |
874 | 0fbcb755 | Stavros Sachtouris | name The server name ✔ ✔ |
875 | 0fbcb755 | Stavros Sachtouris | accessIPv4 IP v4 address **✘** ✔ |
876 | 0fbcb755 | Stavros Sachtouris | accessIPv6 IP v6 address **✘** ✔ |
877 | 0fbcb755 | Stavros Sachtouris | =========== ==================== ======== ========== |
878 | 0fbcb755 | Stavros Sachtouris | |
879 | 68386e00 | Stavros Sachtouris | * Cyclades support multiple network connections per virtual server, which |
880 | 68386e00 | Stavros Sachtouris | explains the above differences in request body attributes. |
881 | 0fbcb755 | Stavros Sachtouris | |
882 | 634ef3a8 | Stavros Sachtouris | *Example Rename Server Request: JSON* |
883 | 634ef3a8 | Stavros Sachtouris | |
884 | 634ef3a8 | Stavros Sachtouris | .. code-block:: javascript |
885 | 634ef3a8 | Stavros Sachtouris | |
886 | 634ef3a8 | Stavros Sachtouris | {"server": {"name": "A new name for my virtual server"}} |
887 | 634ef3a8 | Stavros Sachtouris | |
888 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
889 | 0fbcb755 | Stavros Sachtouris | |
890 | 0fbcb755 | Stavros Sachtouris | =========================== ===================== |
891 | 0fbcb755 | Stavros Sachtouris | Return Code Description |
892 | 0fbcb755 | Stavros Sachtouris | =========================== ===================== |
893 | 0fbcb755 | Stavros Sachtouris | 204 (OK) Request succeeded |
894 | 0fbcb755 | Stavros Sachtouris | 400 (Bad Request) Malformed request or malformed server id |
895 | 0fbcb755 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
896 | 0fbcb755 | Stavros Sachtouris | 403 (Forbidden) User is not allowed to perform this operation |
897 | 0fbcb755 | Stavros Sachtouris | 404 (Not Found) Server not found |
898 | 0fbcb755 | Stavros Sachtouris | 415 (Bad Media Type) |
899 | 0fbcb755 | Stavros Sachtouris | 409 (Build In Progress) Server is not ready yet |
900 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
901 | e7f266c3 | Stavros Sachtouris | \ internal error |
902 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) No available backends or service currently |
903 | e7f266c3 | Stavros Sachtouris | \ unavailable |
904 | 0fbcb755 | Stavros Sachtouris | =========================== ===================== |
905 | 0fbcb755 | Stavros Sachtouris | |
906 | 68386e00 | Stavros Sachtouris | .. note:: In case of a 204 return code, there will be no request results |
907 | 68386e00 | Stavros Sachtouris | according to the Cyclades API. Compute OS API suggests that response should |
908 | 68386e00 | Stavros Sachtouris | include the new server details. |
909 | 0fbcb755 | Stavros Sachtouris | |
910 | eb775de0 | Stavros Sachtouris | Delete Server |
911 | eb775de0 | Stavros Sachtouris | ............. |
912 | eb775de0 | Stavros Sachtouris | |
913 | 68386e00 | Stavros Sachtouris | Delete a virtual server. When a server is deleted, all its connections are |
914 | 68386e00 | Stavros Sachtouris | deleted as well. |
915 | 68386e00 | Stavros Sachtouris | |
916 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
917 | 68386e00 | Stavros Sachtouris | |
918 | eb775de0 | Stavros Sachtouris | ======================== ====== ======== ========== |
919 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
920 | eb775de0 | Stavros Sachtouris | ======================== ====== ======== ========== |
921 | eb775de0 | Stavros Sachtouris | ``/servers/<server id>`` DELETE ✔ ✔ |
922 | eb775de0 | Stavros Sachtouris | ======================== ====== ======== ========== |
923 | eb775de0 | Stavros Sachtouris | |
924 | e31f6f23 | Stavros Sachtouris | * **server-id** is the identifier of the virtual server. |
925 | eb775de0 | Stavros Sachtouris | |
926 | eb775de0 | Stavros Sachtouris | | |
927 | eb775de0 | Stavros Sachtouris | |
928 | eb775de0 | Stavros Sachtouris | ============== ========================= ======== ========== |
929 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
930 | eb775de0 | Stavros Sachtouris | ============== ========================= ======== ========== |
931 | eb775de0 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
932 | eb775de0 | Stavros Sachtouris | ============== ========================= ======== ========== |
933 | eb775de0 | Stavros Sachtouris | |
934 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
935 | 68386e00 | Stavros Sachtouris | |
936 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
937 | 68386e00 | Stavros Sachtouris | |
938 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
939 | eb775de0 | Stavros Sachtouris | |
940 | eb775de0 | Stavros Sachtouris | =========================== ===================== |
941 | eb775de0 | Stavros Sachtouris | Return Code Description |
942 | eb775de0 | Stavros Sachtouris | =========================== ===================== |
943 | eb775de0 | Stavros Sachtouris | 204 (OK) Request succeeded |
944 | eb775de0 | Stavros Sachtouris | 400 (Bad Request) Malformed server id or machine already deleted |
945 | eb775de0 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
946 | eb775de0 | Stavros Sachtouris | 404 (Not Found) Server not found |
947 | eb775de0 | Stavros Sachtouris | 409 (Build In Progress) Server is not ready yet |
948 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
949 | e7f266c3 | Stavros Sachtouris | \ internal error |
950 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) Action not supported or service currently |
951 | e7f266c3 | Stavros Sachtouris | \ unavailable |
952 | eb775de0 | Stavros Sachtouris | =========================== ===================== |
953 | eb775de0 | Stavros Sachtouris | |
954 | 68386e00 | Stavros Sachtouris | .. note:: In case of a 204 code, response body should be empty |
955 | 2cd1c00a | Giorgos Verigakis | |
956 | e31f6f23 | Stavros Sachtouris | List Server Addresses |
957 | e31f6f23 | Stavros Sachtouris | ..................... |
958 | 4935e468 | Stavros Sachtouris | |
959 | 68386e00 | Stavros Sachtouris | List all network connections of a server. In Cyclades API, connections are |
960 | 68386e00 | Stavros Sachtouris | represented as Network Connection Interfaces (NICs), which describe a server - |
961 | 68386e00 | Stavros Sachtouris | network relation through their respective identifiers. This mechanism ensures |
962 | 68386e00 | Stavros Sachtouris | flexibility and multiple networks connecting the same virtual servers. |
963 | 68386e00 | Stavros Sachtouris | |
964 | 68386e00 | Stavros Sachtouris | The Synnefo/Cyclades approach in this matter differs substantially to the |
965 | 68386e00 | Stavros Sachtouris | `one suggested by the OS/Compute API <http://docs.openstack.org/api/openstack-compute/2/content/List_Addresses-d1e3014.html>`_. |
966 | 68386e00 | Stavros Sachtouris | |
967 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
968 | 4935e468 | Stavros Sachtouris | |
969 | 4935e468 | Stavros Sachtouris | ============================ ====== ======== ========== |
970 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
971 | 4935e468 | Stavros Sachtouris | ============================ ====== ======== ========== |
972 | 4935e468 | Stavros Sachtouris | ``/servers/<server id>/ips`` GET ✔ ✔ |
973 | 4935e468 | Stavros Sachtouris | ============================ ====== ======== ========== |
974 | 4935e468 | Stavros Sachtouris | |
975 | 4935e468 | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
976 | 4935e468 | Stavros Sachtouris | |
977 | 4935e468 | Stavros Sachtouris | | |
978 | 4935e468 | Stavros Sachtouris | |
979 | 4935e468 | Stavros Sachtouris | ============== ========================= ======== ========== |
980 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
981 | 4935e468 | Stavros Sachtouris | ============== ========================= ======== ========== |
982 | 4935e468 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
983 | 4935e468 | Stavros Sachtouris | ============== ========================= ======== ========== |
984 | 4935e468 | Stavros Sachtouris | |
985 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
986 | 4935e468 | Stavros Sachtouris | |
987 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
988 | 4935e468 | Stavros Sachtouris | |
989 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
990 | 4935e468 | Stavros Sachtouris | |
991 | 4935e468 | Stavros Sachtouris | =========================== ===================== |
992 | 4935e468 | Stavros Sachtouris | Return Code Description |
993 | 4935e468 | Stavros Sachtouris | =========================== ===================== |
994 | 4935e468 | Stavros Sachtouris | 200 (OK) Request succeeded |
995 | 4935e468 | Stavros Sachtouris | 400 (Bad Request) Malformed server id or machine already deleted |
996 | 4935e468 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
997 | 4935e468 | Stavros Sachtouris | 404 (Not Found) Server not found |
998 | 4935e468 | Stavros Sachtouris | 409 (Build In Progress) Server is not ready yet |
999 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1000 | e7f266c3 | Stavros Sachtouris | \ internal error |
1001 | 4935e468 | Stavros Sachtouris | 503 (Service Unavailable) Service currently unavailable |
1002 | 4935e468 | Stavros Sachtouris | =========================== ===================== |
1003 | 4935e468 | Stavros Sachtouris | |
1004 | 68386e00 | Stavros Sachtouris | Response body contents:: |
1005 | 68386e00 | Stavros Sachtouris | |
1006 | 68386e00 | Stavros Sachtouris | addresses: {values: [ |
1007 | 68386e00 | Stavros Sachtouris | { |
1008 | 68386e00 | Stavros Sachtouris | <NIC attribute>: <value>, |
1009 | 68386e00 | Stavros Sachtouris | ... |
1010 | 68386e00 | Stavros Sachtouris | }, |
1011 | 68386e00 | Stavros Sachtouris | ... |
1012 | 68386e00 | Stavros Sachtouris | ]} |
1013 | 4935e468 | Stavros Sachtouris | |
1014 | 68386e00 | Stavros Sachtouris | A Network Interface Connection (or NIC) connects the current server to a |
1015 | 68386e00 | Stavros Sachtouris | network, through their respective identifiers. More information in NIC |
1016 | 68386e00 | Stavros Sachtouris | attributes are `enlisted here <#nic-ref>`_. |
1017 | 4935e468 | Stavros Sachtouris | |
1018 | 634ef3a8 | Stavros Sachtouris | *Example List Addresses: JSON* |
1019 | 4935e468 | Stavros Sachtouris | |
1020 | 4935e468 | Stavros Sachtouris | .. code-block:: javascript |
1021 | 4935e468 | Stavros Sachtouris | |
1022 | 4935e468 | Stavros Sachtouris | { |
1023 | 4935e468 | Stavros Sachtouris | "addresses": { |
1024 | 4935e468 | Stavros Sachtouris | "values": [ |
1025 | e31f6f23 | Stavros Sachtouris | { |
1026 | 68386e00 | Stavros Sachtouris | "id": "nic-25455-0" |
1027 | e31f6f23 | Stavros Sachtouris | "network_id": "1", |
1028 | e31f6f23 | Stavros Sachtouris | "mac_address": "aa:00:03:7a:84:bb", |
1029 | e31f6f23 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
1030 | e31f6f23 | Stavros Sachtouris | "ipv4": "192.168.0.27", |
1031 | e31f6f23 | Stavros Sachtouris | "ipv6": "2001:646:2ffc:1222:a820:3fd:fe7a:84bb", |
1032 | e31f6f23 | Stavros Sachtouris | }, { |
1033 | 68386e00 | Stavros Sachtouris | "id": "nic-25455-1" |
1034 | e31f6f23 | Stavros Sachtouris | "network_id": "7", |
1035 | e31f6f23 | Stavros Sachtouris | "mac_address": "aa:00:03:7a:84:cc", |
1036 | e31f6f23 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
1037 | e31f6f23 | Stavros Sachtouris | "ipv4": "192.168.0.28", |
1038 | e31f6f23 | Stavros Sachtouris | "ipv6": "2002:646:2fec:1222:a820:3fd:fe7a:84bc", |
1039 | e31f6f23 | Stavros Sachtouris | }, |
1040 | 4935e468 | Stavros Sachtouris | ] |
1041 | 4935e468 | Stavros Sachtouris | } |
1042 | 4935e468 | Stavros Sachtouris | } |
1043 | 4935e468 | Stavros Sachtouris | |
1044 | 68386e00 | Stavros Sachtouris | Get Server NICs by Network |
1045 | 68386e00 | Stavros Sachtouris | .......................... |
1046 | 68386e00 | Stavros Sachtouris | |
1047 | 68386e00 | Stavros Sachtouris | Return the NIC that connects a server to a network. |
1048 | 68386e00 | Stavros Sachtouris | |
1049 | 68386e00 | Stavros Sachtouris | The semantics of this operation are substantially different to the respective |
1050 | 68386e00 | Stavros Sachtouris | OS/Compute |
1051 | 68386e00 | Stavros Sachtouris | `List Addresses by Network semantics <http://docs.openstack.org/api/openstack-compute/2/content/List_Addresses_by_Network-d1e3118.html>`_. |
1052 | 8e3906eb | Stavros Sachtouris | |
1053 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1054 | 8e3906eb | Stavros Sachtouris | |
1055 | 8e3906eb | Stavros Sachtouris | ========================================= ====== ======== ========== |
1056 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1057 | 8e3906eb | Stavros Sachtouris | ========================================= ====== ======== ========== |
1058 | 8e3906eb | Stavros Sachtouris | ``/servers/<server id>/ips/<network id>`` GET ✔ ✔ |
1059 | 8e3906eb | Stavros Sachtouris | ========================================= ====== ======== ========== |
1060 | 8e3906eb | Stavros Sachtouris | |
1061 | 68386e00 | Stavros Sachtouris | * **server id** is the identifier of the virtual server |
1062 | 8e3906eb | Stavros Sachtouris | |
1063 | 68386e00 | Stavros Sachtouris | * **network id** is the identifier of the network |
1064 | 8e3906eb | Stavros Sachtouris | |
1065 | 8e3906eb | Stavros Sachtouris | | |
1066 | 8e3906eb | Stavros Sachtouris | |
1067 | 8e3906eb | Stavros Sachtouris | ============== ========================= ======== ========== |
1068 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1069 | 8e3906eb | Stavros Sachtouris | ============== ========================= ======== ========== |
1070 | 8e3906eb | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1071 | 8e3906eb | Stavros Sachtouris | ============== ========================= ======== ========== |
1072 | 8e3906eb | Stavros Sachtouris | |
1073 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1074 | 8e3906eb | Stavros Sachtouris | |
1075 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
1076 | 8e3906eb | Stavros Sachtouris | |
1077 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1078 | 8e3906eb | Stavros Sachtouris | |
1079 | 8e3906eb | Stavros Sachtouris | =========================== ===================== |
1080 | 8e3906eb | Stavros Sachtouris | Return Code Description |
1081 | 8e3906eb | Stavros Sachtouris | =========================== ===================== |
1082 | 8e3906eb | Stavros Sachtouris | 200 (OK) Request succeeded |
1083 | 8e3906eb | Stavros Sachtouris | 400 (Bad Request) Malformed server id or machine already deleted |
1084 | 8e3906eb | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1085 | 8e3906eb | Stavros Sachtouris | 404 (Not Found) Server not found |
1086 | 8e3906eb | Stavros Sachtouris | 409 (Build In Progress) Server is not ready yet |
1087 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1088 | e7f266c3 | Stavros Sachtouris | \ internal error |
1089 | 8e3906eb | Stavros Sachtouris | 503 (Service Unavailable) Service currently unavailable |
1090 | 8e3906eb | Stavros Sachtouris | =========================== ===================== |
1091 | 8e3906eb | Stavros Sachtouris | |
1092 | 68386e00 | Stavros Sachtouris | | |
1093 | 68386e00 | Stavros Sachtouris | |
1094 | 68386e00 | Stavros Sachtouris | Response body contents:: |
1095 | 68386e00 | Stavros Sachtouris | |
1096 | 68386e00 | Stavros Sachtouris | network: { |
1097 | 68386e00 | Stavros Sachtouris | <NIC attributes>: <value>, |
1098 | 68386e00 | Stavros Sachtouris | ... |
1099 | 68386e00 | Stavros Sachtouris | } |
1100 | 8e3906eb | Stavros Sachtouris | |
1101 | 3458183d | Constantinos Venetsanopoulos | Network Interface Connection (NIC) attributes are listed `here <#nic-ref>`_. |
1102 | 8e3906eb | Stavros Sachtouris | |
1103 | 68386e00 | Stavros Sachtouris | **List Server NICs Example with server id 25455, network id 7: JSON** |
1104 | 8e3906eb | Stavros Sachtouris | |
1105 | 8e3906eb | Stavros Sachtouris | .. code-block:: javascript |
1106 | 8e3906eb | Stavros Sachtouris | |
1107 | 8e3906eb | Stavros Sachtouris | { |
1108 | 8e3906eb | Stavros Sachtouris | "network": { |
1109 | 68386e00 | Stavros Sachtouris | "id": "nic-25455-0" |
1110 | e31f6f23 | Stavros Sachtouris | "network_id": "7", |
1111 | e31f6f23 | Stavros Sachtouris | "mac_address": "aa:00:03:7a:84:bb", |
1112 | e31f6f23 | Stavros Sachtouris | "firewallProfile": "DISABLED", |
1113 | e31f6f23 | Stavros Sachtouris | "ipv4": "192.168.0.27", |
1114 | e31f6f23 | Stavros Sachtouris | "ipv6": "2001:646:2ffc:1222:a820:3fd:fe7a:84bb", |
1115 | 8e3906eb | Stavros Sachtouris | } |
1116 | 8e3906eb | Stavros Sachtouris | } |
1117 | 8e3906eb | Stavros Sachtouris | |
1118 | 2cd1c00a | Giorgos Verigakis | |
1119 | 68386e00 | Stavros Sachtouris | List Server Metadata |
1120 | 2cd1c00a | Giorgos Verigakis | .................... |
1121 | 2cd1c00a | Giorgos Verigakis | |
1122 | 68386e00 | Stavros Sachtouris | List the metadata of a server |
1123 | 68386e00 | Stavros Sachtouris | |
1124 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
1125 | 68386e00 | Stavros Sachtouris | besides the different URI. |
1126 | 68386e00 | Stavros Sachtouris | |
1127 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1128 | a5ec880a | Stavros Sachtouris | |
1129 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1130 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1131 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1132 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/meta`` GET ✔ **✘** |
1133 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/metadata`` GET **✘** ✔ |
1134 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1135 | a5ec880a | Stavros Sachtouris | |
1136 | a5ec880a | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
1137 | a5ec880a | Stavros Sachtouris | |
1138 | a5ec880a | Stavros Sachtouris | | |
1139 | a5ec880a | Stavros Sachtouris | |
1140 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1141 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1142 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1143 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1144 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1145 | a5ec880a | Stavros Sachtouris | |
1146 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1147 | 68386e00 | Stavros Sachtouris | |
1148 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
1149 | 68386e00 | Stavros Sachtouris | |
1150 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1151 | a5ec880a | Stavros Sachtouris | |
1152 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1153 | a5ec880a | Stavros Sachtouris | Return Code Description |
1154 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1155 | a5ec880a | Stavros Sachtouris | 200 (OK) Request succeeded |
1156 | a5ec880a | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Malformed request |
1157 | a5ec880a | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1158 | a5ec880a | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
1159 | a5ec880a | Stavros Sachtouris | 404 (Not Found) Server not found |
1160 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1161 | e7f266c3 | Stavros Sachtouris | \ internal error |
1162 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1163 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1164 | a5ec880a | Stavros Sachtouris | |
1165 | 68386e00 | Stavros Sachtouris | Response body contents:: |
1166 | 68386e00 | Stavros Sachtouris | |
1167 | 68386e00 | Stavros Sachtouris | metadata: {values: |
1168 | 68386e00 | Stavros Sachtouris | { |
1169 | 68386e00 | Stavros Sachtouris | <metadatum key>: <value>, |
1170 | 68386e00 | Stavros Sachtouris | ... |
1171 | 68386e00 | Stavros Sachtouris | } |
1172 | 68386e00 | Stavros Sachtouris | } |
1173 | 68386e00 | Stavros Sachtouris | |
1174 | 634ef3a8 | Stavros Sachtouris | *Example List Server Metadata: JSON* |
1175 | 68386e00 | Stavros Sachtouris | |
1176 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1177 | a5ec880a | Stavros Sachtouris | |
1178 | 3458183d | Constantinos Venetsanopoulos | { |
1179 | e31f6f23 | Stavros Sachtouris | ""metadata": { |
1180 | e31f6f23 | Stavros Sachtouris | "values": { |
1181 | e31f6f23 | Stavros Sachtouris | "OS": "Linux", |
1182 | e31f6f23 | Stavros Sachtouris | "users": "root" |
1183 | a5ec880a | Stavros Sachtouris | } |
1184 | a5ec880a | Stavros Sachtouris | } |
1185 | a5ec880a | Stavros Sachtouris | } |
1186 | a5ec880a | Stavros Sachtouris | |
1187 | 68386e00 | Stavros Sachtouris | .. note:: In OS/Compute API the ``values`` level is missing from the response. |
1188 | a5ec880a | Stavros Sachtouris | |
1189 | a5ec880a | Stavros Sachtouris | Set / Update Server Metadata |
1190 | a5ec880a | Stavros Sachtouris | ............................ |
1191 | a5ec880a | Stavros Sachtouris | |
1192 | a5ec880a | Stavros Sachtouris | In Cyclades API, setting new metadata and updating the values of existing ones |
1193 | 68386e00 | Stavros Sachtouris | is achieved with the same type of request (``POST``), while in OS/Compute API |
1194 | 68386e00 | Stavros Sachtouris | there are two separate request types (``PUT`` and ``POST`` for |
1195 | a5ec880a | Stavros Sachtouris | `setting new <http://docs.openstack.org/api/openstack-compute/2/content/Create_or_Replace_Metadata-d1e5358.html>`_ |
1196 | a5ec880a | Stavros Sachtouris | and |
1197 | a5ec880a | Stavros Sachtouris | `updating existing <http://docs.openstack.org/api/openstack-compute/2/content/Update_Metadata-d1e5208.html>`_ |
1198 | a5ec880a | Stavros Sachtouris | metadata, respectively). |
1199 | a5ec880a | Stavros Sachtouris | |
1200 | c347ba83 | Stavros Sachtouris | In Cyclades API, metadata keys which are not referred by the operation will |
1201 | 68386e00 | Stavros Sachtouris | remain intact, while metadata referred by the operation will be overwritten. |
1202 | 68386e00 | Stavros Sachtouris | |
1203 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1204 | a5ec880a | Stavros Sachtouris | |
1205 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1206 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1207 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1208 | c347ba83 | Stavros Sachtouris | ``/servers/<server-id>/meta`` POST ✔ **✘** |
1209 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/metadata`` PUT **✘** ✔ |
1210 | 68386e00 | Stavros Sachtouris | ``/servers/<server-id>/metadata`` POST **✘** ✔ |
1211 | a5ec880a | Stavros Sachtouris | ================================= ====== ======== ========== |
1212 | a5ec880a | Stavros Sachtouris | |
1213 | a5ec880a | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
1214 | a5ec880a | Stavros Sachtouris | |
1215 | a5ec880a | Stavros Sachtouris | | |
1216 | a5ec880a | Stavros Sachtouris | |
1217 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1218 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1219 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1220 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1221 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
1222 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
1223 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1224 | a5ec880a | Stavros Sachtouris | |
1225 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
1226 | 634ef3a8 | Stavros Sachtouris | |
1227 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
1228 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
1229 | 634ef3a8 | Stavros Sachtouris | Content-Length: 56 |
1230 | 634ef3a8 | Stavros Sachtouris | |
1231 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1232 | a5ec880a | Stavros Sachtouris | |
1233 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1234 | a5ec880a | Stavros Sachtouris | |
1235 | 68386e00 | Stavros Sachtouris | metadata: { |
1236 | 68386e00 | Stavros Sachtouris | <metadatum key>: <value>, |
1237 | 68386e00 | Stavros Sachtouris | ... |
1238 | 68386e00 | Stavros Sachtouris | } |
1239 | a5ec880a | Stavros Sachtouris | |
1240 | 634ef3a8 | Stavros Sachtouris | *Example Request Set / Update Server Metadata: JSON* |
1241 | 68386e00 | Stavros Sachtouris | |
1242 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1243 | 68386e00 | Stavros Sachtouris | |
1244 | 68386e00 | Stavros Sachtouris | {"metadata": {"role": "webmail", "users": "root,maild"}} |
1245 | 68386e00 | Stavros Sachtouris | |
1246 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1247 | a5ec880a | Stavros Sachtouris | |
1248 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1249 | a5ec880a | Stavros Sachtouris | Return Code Description |
1250 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1251 | a5ec880a | Stavros Sachtouris | 201 (OK) Request succeeded |
1252 | a5ec880a | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Malformed request |
1253 | a5ec880a | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1254 | a5ec880a | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
1255 | a5ec880a | Stavros Sachtouris | 404 (Not Found) Server not found |
1256 | a5ec880a | Stavros Sachtouris | 413 (OverLimit) Maximum number of metadata exceeded |
1257 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1258 | e7f266c3 | Stavros Sachtouris | \ internal error |
1259 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1260 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1261 | a5ec880a | Stavros Sachtouris | |
1262 | 68386e00 | Stavros Sachtouris | Response body contents:: |
1263 | a5ec880a | Stavros Sachtouris | |
1264 | 68386e00 | Stavros Sachtouris | metadata: { |
1265 | 68386e00 | Stavros Sachtouris | <metadatum key>: <value>, |
1266 | 68386e00 | Stavros Sachtouris | ... |
1267 | 68386e00 | Stavros Sachtouris | } |
1268 | 68386e00 | Stavros Sachtouris | |
1269 | 634ef3a8 | Stavros Sachtouris | *Example Response Set / Update Server Metadata: JSON* |
1270 | 68386e00 | Stavros Sachtouris | |
1271 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1272 | a5ec880a | Stavros Sachtouris | |
1273 | 68386e00 | Stavros Sachtouris | {"metadata": {"OS": "Linux", "role": "webmail", "users": "root,maild"}} |
1274 | a5ec880a | Stavros Sachtouris | |
1275 | e31f6f23 | Stavros Sachtouris | Get Server Metadata Item |
1276 | e31f6f23 | Stavros Sachtouris | ........................ |
1277 | a5ec880a | Stavros Sachtouris | |
1278 | 68386e00 | Stavros Sachtouris | Get the value of a specific metadatum of a virtual server |
1279 | 68386e00 | Stavros Sachtouris | |
1280 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
1281 | 68386e00 | Stavros Sachtouris | besides the different URI. |
1282 | 68386e00 | Stavros Sachtouris | |
1283 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1284 | a5ec880a | Stavros Sachtouris | |
1285 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1286 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1287 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1288 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/meta/<key>`` GET ✔ **✘** |
1289 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/metadata/<key>`` GET **✘** ✔ |
1290 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1291 | a5ec880a | Stavros Sachtouris | |
1292 | a5ec880a | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
1293 | e31f6f23 | Stavros Sachtouris | |
1294 | e31f6f23 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
1295 | a5ec880a | Stavros Sachtouris | |
1296 | a5ec880a | Stavros Sachtouris | | |
1297 | a5ec880a | Stavros Sachtouris | |
1298 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1299 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1300 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1301 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1302 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1303 | a5ec880a | Stavros Sachtouris | |
1304 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1305 | 68386e00 | Stavros Sachtouris | |
1306 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
1307 | 68386e00 | Stavros Sachtouris | |
1308 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1309 | a5ec880a | Stavros Sachtouris | |
1310 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1311 | a5ec880a | Stavros Sachtouris | Return Code Description |
1312 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1313 | a5ec880a | Stavros Sachtouris | 200 (OK) Request succeeded |
1314 | a5ec880a | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Malformed request |
1315 | a5ec880a | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1316 | a5ec880a | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
1317 | a5ec880a | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
1318 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1319 | e7f266c3 | Stavros Sachtouris | \ internal error |
1320 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1321 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1322 | a5ec880a | Stavros Sachtouris | |
1323 | 68386e00 | Stavros Sachtouris | Response body content:: |
1324 | 68386e00 | Stavros Sachtouris | |
1325 | 68386e00 | Stavros Sachtouris | metadata: {<metadatum key>: <value>} |
1326 | 68386e00 | Stavros Sachtouris | |
1327 | 634ef3a8 | Stavros Sachtouris | *Example Get Server Metadatum for Item 'role', JSON* |
1328 | a5ec880a | Stavros Sachtouris | |
1329 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1330 | 68386e00 | Stavros Sachtouris | |
1331 | 68386e00 | Stavros Sachtouris | {"metadata": {"role": "webmail"}} |
1332 | a5ec880a | Stavros Sachtouris | |
1333 | 68386e00 | Stavros Sachtouris | .. note:: In OS/Compute, ``metadata`` is ``meta`` |
1334 | a5ec880a | Stavros Sachtouris | |
1335 | 8a86499c | Stavros Sachtouris | Update Server Metadatum Item |
1336 | 8a86499c | Stavros Sachtouris | ............................. |
1337 | a5ec880a | Stavros Sachtouris | |
1338 | 68386e00 | Stavros Sachtouris | Set a new or update an existing a metadum value for a virtual server. |
1339 | 68386e00 | Stavros Sachtouris | |
1340 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
1341 | 68386e00 | Stavros Sachtouris | besides the different URI. |
1342 | 68386e00 | Stavros Sachtouris | |
1343 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1344 | a5ec880a | Stavros Sachtouris | |
1345 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1346 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1347 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1348 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/meta/<key>`` PUT ✔ **✘** |
1349 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/metadata/<key>`` PUT **✘** ✔ |
1350 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1351 | a5ec880a | Stavros Sachtouris | |
1352 | a5ec880a | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
1353 | e31f6f23 | Stavros Sachtouris | |
1354 | e31f6f23 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
1355 | a5ec880a | Stavros Sachtouris | |
1356 | a5ec880a | Stavros Sachtouris | | |
1357 | a5ec880a | Stavros Sachtouris | |
1358 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1359 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1360 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1361 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1362 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
1363 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
1364 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1365 | a5ec880a | Stavros Sachtouris | |
1366 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
1367 | 634ef3a8 | Stavros Sachtouris | |
1368 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
1369 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
1370 | 634ef3a8 | Stavros Sachtouris | Content-Length: 29 |
1371 | 634ef3a8 | Stavros Sachtouris | |
1372 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1373 | 68386e00 | Stavros Sachtouris | |
1374 | 68386e00 | Stavros Sachtouris | Request body content:: |
1375 | a5ec880a | Stavros Sachtouris | |
1376 | 68386e00 | Stavros Sachtouris | meta: {<metadatum key>: <value>} |
1377 | 68386e00 | Stavros Sachtouris | |
1378 | 634ef3a8 | Stavros Sachtouris | *Example Request to Set or Update Server Metadatum "role": JSON* |
1379 | e31f6f23 | Stavros Sachtouris | |
1380 | e31f6f23 | Stavros Sachtouris | .. code-block:: javascript |
1381 | a5ec880a | Stavros Sachtouris | |
1382 | 68386e00 | Stavros Sachtouris | {"meta": {"role": "gateway"}} |
1383 | a5ec880a | Stavros Sachtouris | |
1384 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1385 | a5ec880a | Stavros Sachtouris | |
1386 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1387 | a5ec880a | Stavros Sachtouris | Return Code Description |
1388 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1389 | a5ec880a | Stavros Sachtouris | 201 (OK) Request succeeded |
1390 | a5ec880a | Stavros Sachtouris | 400 (Bad Request) Invalid server ID or Malformed request |
1391 | a5ec880a | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1392 | a5ec880a | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
1393 | a5ec880a | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
1394 | a5ec880a | Stavros Sachtouris | 413 (OverLimit) Maximum number of metadata exceeded |
1395 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1396 | e7f266c3 | Stavros Sachtouris | \ internal error |
1397 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1398 | 68386e00 | Stavros Sachtouris | =========================== ==================== |
1399 | a5ec880a | Stavros Sachtouris | |
1400 | 68386e00 | Stavros Sachtouris | Response body content:: |
1401 | a5ec880a | Stavros Sachtouris | |
1402 | 68386e00 | Stavros Sachtouris | meta: {<metadatum key>: <value>} |
1403 | 68386e00 | Stavros Sachtouris | |
1404 | 634ef3a8 | Stavros Sachtouris | *Example Set or Update Server Metadatum "role":"gateway": JSON* |
1405 | 68386e00 | Stavros Sachtouris | |
1406 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1407 | 68386e00 | Stavros Sachtouris | |
1408 | 68386e00 | Stavros Sachtouris | {"meta": {"role": "gateway"}} |
1409 | a5ec880a | Stavros Sachtouris | |
1410 | 0ad49876 | Stavros Sachtouris | Delete Server Metadatum |
1411 | 0ad49876 | Stavros Sachtouris | ....................... |
1412 | a5ec880a | Stavros Sachtouris | |
1413 | 68386e00 | Stavros Sachtouris | Delete a metadatum of a virtual server |
1414 | 68386e00 | Stavros Sachtouris | |
1415 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
1416 | 68386e00 | Stavros Sachtouris | besides the different URI. |
1417 | 68386e00 | Stavros Sachtouris | |
1418 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1419 | a5ec880a | Stavros Sachtouris | |
1420 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1421 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1422 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1423 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/meta/<key>`` DELETE ✔ **✘** |
1424 | a5ec880a | Stavros Sachtouris | ``/servers/<server-id>/metadata/<key>`` DELETE **✘** ✔ |
1425 | a5ec880a | Stavros Sachtouris | ======================================= ====== ======== ========== |
1426 | a5ec880a | Stavros Sachtouris | |
1427 | a5ec880a | Stavros Sachtouris | * **server-id** is the identifier of the virtual server |
1428 | e31f6f23 | Stavros Sachtouris | |
1429 | e31f6f23 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
1430 | a5ec880a | Stavros Sachtouris | |
1431 | a5ec880a | Stavros Sachtouris | | |
1432 | a5ec880a | Stavros Sachtouris | |
1433 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1434 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1435 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1436 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1437 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1438 | a5ec880a | Stavros Sachtouris | |
1439 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1440 | 68386e00 | Stavros Sachtouris | |
1441 | 68386e00 | Stavros Sachtouris | .. note:: Request body should be empty |
1442 | 68386e00 | Stavros Sachtouris | |
1443 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1444 | a5ec880a | Stavros Sachtouris | |
1445 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1446 | a5ec880a | Stavros Sachtouris | Return Code Description |
1447 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1448 | a5ec880a | Stavros Sachtouris | 204 (OK) Request succeeded |
1449 | a5ec880a | Stavros Sachtouris | 400 (Bad Request) Invalid server ID |
1450 | a5ec880a | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1451 | a5ec880a | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
1452 | a5ec880a | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
1453 | a5ec880a | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1454 | e7f266c3 | Stavros Sachtouris | \ internal error |
1455 | a5ec880a | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1456 | a5ec880a | Stavros Sachtouris | =========================== ===================== |
1457 | a5ec880a | Stavros Sachtouris | |
1458 | 68386e00 | Stavros Sachtouris | .. note:: In case of a 204 code, response body should be empty |
1459 | 68386e00 | Stavros Sachtouris | |
1460 | e31f6f23 | Stavros Sachtouris | Server Actions |
1461 | e31f6f23 | Stavros Sachtouris | -------------- |
1462 | e31f6f23 | Stavros Sachtouris | |
1463 | 68386e00 | Stavros Sachtouris | Actions are operations that are achieved through the same type of request |
1464 | 68386e00 | Stavros Sachtouris | (``POST``). There are differences in the implementations of some operations |
1465 | 68386e00 | Stavros Sachtouris | between Synnefo/Cyclades and OS/Compute. Although this document focuses on |
1466 | 68386e00 | Stavros Sachtouris | Synnefo/Cyclades, differences and similarities between the APIs are also |
1467 | 68386e00 | Stavros Sachtouris | briefed. |
1468 | e31f6f23 | Stavros Sachtouris | |
1469 | 8a86499c | Stavros Sachtouris | =============================================== ======== ========== |
1470 | 8a86499c | Stavros Sachtouris | Operations Cyclades OS/Compute |
1471 | 8a86499c | Stavros Sachtouris | =============================================== ======== ========== |
1472 | 8a86499c | Stavros Sachtouris | `Start <#start-server>`_ ✔ **✘** |
1473 | 8a86499c | Stavros Sachtouris | `Shutdown <#shutdown-server>`_ ✔ **✘** |
1474 | 8a86499c | Stavros Sachtouris | `Reboot <#reboot-server>`_ ✔ ✔ |
1475 | 8a86499c | Stavros Sachtouris | `Get Console <#get-server-console>`_ ✔ **✘** |
1476 | 8a86499c | Stavros Sachtouris | `Set Firewall <#set-server-firewall-profile>`_ ✔ **✘** |
1477 | 8a86499c | Stavros Sachtouris | `Change Admin Password <#os-compute-specific>`_ **✘** ✔ |
1478 | 8a86499c | Stavros Sachtouris | `Rebuild <#os-compute-specific>`_ **✘** ✔ |
1479 | 8a86499c | Stavros Sachtouris | `Resize <#os-compute-specific>`_ **✘** ✔ |
1480 | 8a86499c | Stavros Sachtouris | `Confirm Resized <#os-compute-specific>`_ **✘** ✔ |
1481 | 8a86499c | Stavros Sachtouris | `Revert Resized <#os-compute-specific>`_ **✘** ✔ |
1482 | 8a86499c | Stavros Sachtouris | `Create Image <#os-compute-specific>`_ **✘** ✔ |
1483 | 8a86499c | Stavros Sachtouris | =============================================== ======== ========== |
1484 | e31f6f23 | Stavros Sachtouris | |
1485 | 68386e00 | Stavros Sachtouris | .. rubric:: Request |
1486 | e31f6f23 | Stavros Sachtouris | |
1487 | e31f6f23 | Stavros Sachtouris | =============================== ====== ======== ========== |
1488 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1489 | e31f6f23 | Stavros Sachtouris | =============================== ====== ======== ========== |
1490 | e31f6f23 | Stavros Sachtouris | ``/servers/<server id>/action`` POST ✔ ✔ |
1491 | e31f6f23 | Stavros Sachtouris | =============================== ====== ======== ========== |
1492 | e31f6f23 | Stavros Sachtouris | |
1493 | e31f6f23 | Stavros Sachtouris | | |
1494 | e31f6f23 | Stavros Sachtouris | |
1495 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1496 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1497 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1498 | e31f6f23 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1499 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
1500 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
1501 | e31f6f23 | Stavros Sachtouris | ============== ========================= ======== ========== |
1502 | e31f6f23 | Stavros Sachtouris | |
1503 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
1504 | 634ef3a8 | Stavros Sachtouris | |
1505 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
1506 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
1507 | 634ef3a8 | Stavros Sachtouris | Content-Length: 32 |
1508 | 634ef3a8 | Stavros Sachtouris | |
1509 | 68386e00 | Stavros Sachtouris | .. note:: Request parameters should be empty |
1510 | 68386e00 | Stavros Sachtouris | |
1511 | 68386e00 | Stavros Sachtouris | .. note:: Request body varies between operations (see bellow) |
1512 | 68386e00 | Stavros Sachtouris | |
1513 | 68386e00 | Stavros Sachtouris | .. rubric:: Response |
1514 | e31f6f23 | Stavros Sachtouris | |
1515 | e31f6f23 | Stavros Sachtouris | =========================== ===================== |
1516 | e31f6f23 | Stavros Sachtouris | Return Code Description |
1517 | e31f6f23 | Stavros Sachtouris | =========================== ===================== |
1518 | e31f6f23 | Stavros Sachtouris | 200 (OK) Request succeeded (for console operation) |
1519 | e31f6f23 | Stavros Sachtouris | 202 (OK) Request succeeded |
1520 | e31f6f23 | Stavros Sachtouris | 400 (Bad Request) Invalid request or unknown action |
1521 | e31f6f23 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1522 | e31f6f23 | Stavros Sachtouris | 403 (Forbidden) User is not allowed to perform this operation |
1523 | e31f6f23 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1524 | e31f6f23 | Stavros Sachtouris | \ internal error |
1525 | e31f6f23 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1526 | e31f6f23 | Stavros Sachtouris | =========================== ===================== |
1527 | e31f6f23 | Stavros Sachtouris | |
1528 | 68386e00 | Stavros Sachtouris | .. note:: Response body varies between operations (see bellow) |
1529 | 68386e00 | Stavros Sachtouris | |
1530 | e31f6f23 | Stavros Sachtouris | Start server |
1531 | e31f6f23 | Stavros Sachtouris | ................ |
1532 | e31f6f23 | Stavros Sachtouris | |
1533 | e31f6f23 | Stavros Sachtouris | This operation transitions a server from a STOPPED to an ACTIVE state. |
1534 | e31f6f23 | Stavros Sachtouris | |
1535 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1536 | e31f6f23 | Stavros Sachtouris | |
1537 | 68386e00 | Stavros Sachtouris | start: {} |
1538 | e31f6f23 | Stavros Sachtouris | |
1539 | 634ef3a8 | Stavros Sachtouris | *Example Start Server: JSON* |
1540 | 68386e00 | Stavros Sachtouris | |
1541 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1542 | 68386e00 | Stavros Sachtouris | |
1543 | 68386e00 | Stavros Sachtouris | {"start": {}} |
1544 | 68386e00 | Stavros Sachtouris | |
1545 | 68386e00 | Stavros Sachtouris | .. note:: Response body should be empty |
1546 | e31f6f23 | Stavros Sachtouris | |
1547 | e31f6f23 | Stavros Sachtouris | Reboot Server |
1548 | e31f6f23 | Stavros Sachtouris | ............. |
1549 | e31f6f23 | Stavros Sachtouris | |
1550 | e31f6f23 | Stavros Sachtouris | This operation transitions a server from ``ACTIVE`` to ``REBOOT`` and then |
1551 | 68386e00 | Stavros Sachtouris | ``ACTIVE`` again. |
1552 | e31f6f23 | Stavros Sachtouris | |
1553 | 68386e00 | Stavros Sachtouris | Synnefo and OS/Compute APIs offer two reboot modes: ``soft`` |
1554 | 68386e00 | Stavros Sachtouris | and ``hard``. OS/Compute distinguishes between the two intermediate states |
1555 | 68386e00 | Stavros Sachtouris | (``REBOOT`` and ``HARD_REBOOT``) while rebooting, while Synnefo/Cyclades use |
1556 | 634ef3a8 | Stavros Sachtouris | only the ``REBOOT`` term. The expected behavior is the same, though. |
1557 | e31f6f23 | Stavros Sachtouris | |
1558 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1559 | 68386e00 | Stavros Sachtouris | |
1560 | 68386e00 | Stavros Sachtouris | reboot: {type: <reboot type>} |
1561 | e31f6f23 | Stavros Sachtouris | |
1562 | e31f6f23 | Stavros Sachtouris | * **reboot type** can be either ``SOFT`` or ``HARD``. |
1563 | e31f6f23 | Stavros Sachtouris | |
1564 | 634ef3a8 | Stavros Sachtouris | *Example (soft) Reboot Server: JSON* |
1565 | e31f6f23 | Stavros Sachtouris | |
1566 | e31f6f23 | Stavros Sachtouris | .. code-block:: javascript |
1567 | 3458183d | Constantinos Venetsanopoulos | |
1568 | 68386e00 | Stavros Sachtouris | {"reboot" : { "type": "soft"}} |
1569 | 68386e00 | Stavros Sachtouris | |
1570 | 68386e00 | Stavros Sachtouris | .. note:: Response body should be empty |
1571 | e31f6f23 | Stavros Sachtouris | |
1572 | e31f6f23 | Stavros Sachtouris | Shutdown server |
1573 | e31f6f23 | Stavros Sachtouris | ............... |
1574 | e31f6f23 | Stavros Sachtouris | |
1575 | e31f6f23 | Stavros Sachtouris | This operation transitions a server from an ACTIVE to a STOPPED state. |
1576 | e31f6f23 | Stavros Sachtouris | |
1577 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1578 | 68386e00 | Stavros Sachtouris | |
1579 | 68386e00 | Stavros Sachtouris | shutdown: {} |
1580 | 68386e00 | Stavros Sachtouris | |
1581 | 634ef3a8 | Stavros Sachtouris | *Example Shutdown Server: JSON* |
1582 | 68386e00 | Stavros Sachtouris | |
1583 | 68386e00 | Stavros Sachtouris | .. code-block:: javascript |
1584 | e31f6f23 | Stavros Sachtouris | |
1585 | e31f6f23 | Stavros Sachtouris | {"shutdown": {}} |
1586 | e31f6f23 | Stavros Sachtouris | |
1587 | 68386e00 | Stavros Sachtouris | .. note:: Response body should be empty |
1588 | 68386e00 | Stavros Sachtouris | |
1589 | e31f6f23 | Stavros Sachtouris | Get Server Console |
1590 | e31f6f23 | Stavros Sachtouris | .................. |
1591 | e31f6f23 | Stavros Sachtouris | |
1592 | 68386e00 | Stavros Sachtouris | .. note:: This operation is not part of OS/Compute API |
1593 | 68386e00 | Stavros Sachtouris | |
1594 | e31f6f23 | Stavros Sachtouris | The console operation arranges for an OOB console of the specified type. Only |
1595 | e31f6f23 | Stavros Sachtouris | consoles of type ``vnc`` are supported for now. Cyclades server uses a running |
1596 | e31f6f23 | Stavros Sachtouris | instance of vncauthproxy to setup proper VNC forwarding with a random password, |
1597 | e31f6f23 | Stavros Sachtouris | then returns the necessary VNC connection info to the caller. |
1598 | e31f6f23 | Stavros Sachtouris | |
1599 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1600 | 68386e00 | Stavros Sachtouris | |
1601 | 68386e00 | Stavros Sachtouris | console: {type: vnc} |
1602 | 68386e00 | Stavros Sachtouris | |
1603 | 634ef3a8 | Stavros Sachtouris | *Example Get Server Console: JSON* |
1604 | e31f6f23 | Stavros Sachtouris | |
1605 | e31f6f23 | Stavros Sachtouris | .. code-block:: javascript |
1606 | e31f6f23 | Stavros Sachtouris | |
1607 | e31f6f23 | Stavros Sachtouris | {"console": {"type": "vnc" } |
1608 | e31f6f23 | Stavros Sachtouris | |
1609 | 68386e00 | Stavros Sachtouris | Response body contents:: |
1610 | e31f6f23 | Stavros Sachtouris | |
1611 | 68386e00 | Stavros Sachtouris | console: { |
1612 | 68386e00 | Stavros Sachtouris | <vnc attribute>: <value>, |
1613 | 68386e00 | Stavros Sachtouris | ... |
1614 | 68386e00 | Stavros Sachtouris | } |
1615 | e31f6f23 | Stavros Sachtouris | |
1616 | 68386e00 | Stavros Sachtouris | ============== ====================== |
1617 | 3458183d | Constantinos Venetsanopoulos | VNC Attributes Description |
1618 | 68386e00 | Stavros Sachtouris | ============== ====================== |
1619 | 68386e00 | Stavros Sachtouris | host The vncprocy host |
1620 | 68386e00 | Stavros Sachtouris | port vncprocy port |
1621 | 68386e00 | Stavros Sachtouris | password Temporary password |
1622 | 68386e00 | Stavros Sachtouris | type Connection type (only VNC) |
1623 | 68386e00 | Stavros Sachtouris | ============== ====================== |
1624 | e31f6f23 | Stavros Sachtouris | |
1625 | 634ef3a8 | Stavros Sachtouris | *Example Action Console Response: JSON* |
1626 | e31f6f23 | Stavros Sachtouris | |
1627 | e31f6f23 | Stavros Sachtouris | .. code-block:: javascript |
1628 | e31f6f23 | Stavros Sachtouris | |
1629 | e31f6f23 | Stavros Sachtouris | { |
1630 | e31f6f23 | Stavros Sachtouris | "console": { |
1631 | e31f6f23 | Stavros Sachtouris | "type": "vnc", |
1632 | e31f6f23 | Stavros Sachtouris | "host": "vm42.example.org", |
1633 | e31f6f23 | Stavros Sachtouris | "port": 1234, |
1634 | e31f6f23 | Stavros Sachtouris | "password": "513NR14PN0T" |
1635 | e31f6f23 | Stavros Sachtouris | } |
1636 | e31f6f23 | Stavros Sachtouris | } |
1637 | e31f6f23 | Stavros Sachtouris | |
1638 | e31f6f23 | Stavros Sachtouris | Set Server Firewall Profile |
1639 | e31f6f23 | Stavros Sachtouris | ........................... |
1640 | e31f6f23 | Stavros Sachtouris | |
1641 | e31f6f23 | Stavros Sachtouris | The firewallProfile function sets a firewall profile for the public interface |
1642 | e31f6f23 | Stavros Sachtouris | of a server. |
1643 | e31f6f23 | Stavros Sachtouris | |
1644 | 68386e00 | Stavros Sachtouris | Request body contents:: |
1645 | e31f6f23 | Stavros Sachtouris | |
1646 | 68386e00 | Stavros Sachtouris | firewallProfile: { profile: <firewall profile>} |
1647 | e31f6f23 | Stavros Sachtouris | |
1648 | e31f6f23 | Stavros Sachtouris | * **firewall profile** can be ``ENABLED``, ``DISABLED`` or ``PROTECTED`` |
1649 | e31f6f23 | Stavros Sachtouris | |
1650 | 634ef3a8 | Stavros Sachtouris | *Example Action firewallProfile: JSON** |
1651 | e31f6f23 | Stavros Sachtouris | |
1652 | e31f6f23 | Stavros Sachtouris | .. code-block:: javascript |
1653 | e31f6f23 | Stavros Sachtouris | |
1654 | e31f6f23 | Stavros Sachtouris | {"firewallProfile": {"profile": "ENABLED"}} |
1655 | e31f6f23 | Stavros Sachtouris | |
1656 | 68386e00 | Stavros Sachtouris | .. note:: Response body should be empty |
1657 | 68386e00 | Stavros Sachtouris | |
1658 | 68386e00 | Stavros Sachtouris | OS/Compute Specific |
1659 | b38e8fa5 | Stavros Sachtouris | ................... |
1660 | e31f6f23 | Stavros Sachtouris | |
1661 | e31f6f23 | Stavros Sachtouris | The following operations are meaningless or not supported in the context of |
1662 | 68386e00 | Stavros Sachtouris | Synnefo/Cyclades, but are parts of the OS/Compute API: |
1663 | e31f6f23 | Stavros Sachtouris | |
1664 | e31f6f23 | Stavros Sachtouris | * `Change Administrator Password <http://docs.openstack.org/api/openstack-compute/2/content/Change_Password-d1e3234.html>`_ |
1665 | e31f6f23 | Stavros Sachtouris | * `Rebuild Server <http://docs.openstack.org/api/openstack-compute/2/content/Rebuild_Server-d1e3538.html>`_ |
1666 | e31f6f23 | Stavros Sachtouris | * `Resize Server <http://docs.openstack.org/api/openstack-compute/2/content/Resize_Server-d1e3707.html>`_ |
1667 | e31f6f23 | Stavros Sachtouris | * `Confirm Resized Server <http://docs.openstack.org/api/openstack-compute/2/content/Confirm_Resized_Server-d1e3868.html>`_ |
1668 | e31f6f23 | Stavros Sachtouris | * `Revert Resized Server <http://docs.openstack.org/api/openstack-compute/2/content/Revert_Resized_Server-d1e4024.html>`_ |
1669 | e31f6f23 | Stavros Sachtouris | * `Create Image <http://docs.openstack.org/api/openstack-compute/2/content/Create_Image-d1e4655.html>`_ |
1670 | e31f6f23 | Stavros Sachtouris | |
1671 | 6f2a361b | Stavros Sachtouris | |
1672 | 2cd1c00a | Giorgos Verigakis | Flavors |
1673 | 2cd1c00a | Giorgos Verigakis | ------- |
1674 | 2cd1c00a | Giorgos Verigakis | |
1675 | b38e8fa5 | Stavros Sachtouris | A flavor is a hardware configuration for a server. |
1676 | de2e08f6 | Stavros Sachtouris | |
1677 | b16e83ee | Stavros Sachtouris | ==================================== ======================== ====== ======== ========== |
1678 | b16e83ee | Stavros Sachtouris | Description URI Method Cyclades OS/Compute |
1679 | b16e83ee | Stavros Sachtouris | ==================================== ======================== ====== ======== ========== |
1680 | b16e83ee | Stavros Sachtouris | `List <#list-flavors>`_ ``/flavors`` GET ✔ ✔ |
1681 | b16e83ee | Stavros Sachtouris | \ ``/flavors/detail`` GET ✔ **✘** |
1682 | b16e83ee | Stavros Sachtouris | `Get details <#get-flavor-details>`_ ``/flavors/<flavor-id>`` GET ✔ ✔ |
1683 | b16e83ee | Stavros Sachtouris | ==================================== ======================== ====== ======== ========== |
1684 | b16e83ee | Stavros Sachtouris | |
1685 | de2e08f6 | Stavros Sachtouris | List Flavors |
1686 | de2e08f6 | Stavros Sachtouris | ............ |
1687 | de2e08f6 | Stavros Sachtouris | |
1688 | 2b9d64a5 | Stavros Sachtouris | List the flavors that are accessible by the user |
1689 | 2b9d64a5 | Stavros Sachtouris | |
1690 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Request |
1691 | 2b9d64a5 | Stavros Sachtouris | |
1692 | de2e08f6 | Stavros Sachtouris | =================== ====== ======== ========== |
1693 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1694 | de2e08f6 | Stavros Sachtouris | =================== ====== ======== ========== |
1695 | de2e08f6 | Stavros Sachtouris | ``/flavors`` GET ✔ ✔ |
1696 | de2e08f6 | Stavros Sachtouris | ``/flavors/detail`` GET ✔ **✘** |
1697 | de2e08f6 | Stavros Sachtouris | =================== ====== ======== ========== |
1698 | de2e08f6 | Stavros Sachtouris | |
1699 | 2b9d64a5 | Stavros Sachtouris | * The detailed (``/flavors/detail``) listing in Cyclades is semantically |
1700 | 2b9d64a5 | Stavros Sachtouris | similar to OS/Compute regular (``/flavor``) listing. The Cyclades regular |
1701 | 2b9d64a5 | Stavros Sachtouris | listing semantics are Cyclades specific. |
1702 | de2e08f6 | Stavros Sachtouris | |
1703 | de2e08f6 | Stavros Sachtouris | | |
1704 | de2e08f6 | Stavros Sachtouris | |
1705 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1706 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1707 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1708 | b38e8fa5 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1709 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1710 | de2e08f6 | Stavros Sachtouris | |
1711 | de2e08f6 | Stavros Sachtouris | | |
1712 | de2e08f6 | Stavros Sachtouris | |
1713 | de2e08f6 | Stavros Sachtouris | ================= =============== |
1714 | 3458183d | Constantinos Venetsanopoulos | Request Parameter Value |
1715 | de2e08f6 | Stavros Sachtouris | ================= =============== |
1716 | de2e08f6 | Stavros Sachtouris | json Respond in json |
1717 | 3458183d | Constantinos Venetsanopoulos | xml Respond in xml |
1718 | de2e08f6 | Stavros Sachtouris | ================= =============== |
1719 | de2e08f6 | Stavros Sachtouris | |
1720 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request body should be empty |
1721 | 2b9d64a5 | Stavros Sachtouris | |
1722 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Response |
1723 | de2e08f6 | Stavros Sachtouris | |
1724 | de2e08f6 | Stavros Sachtouris | =========================== ===================== |
1725 | de2e08f6 | Stavros Sachtouris | Return Code Description |
1726 | de2e08f6 | Stavros Sachtouris | =========================== ===================== |
1727 | de2e08f6 | Stavros Sachtouris | 200 (OK) Request succeeded |
1728 | 23a2f796 | Stavros Sachtouris | 400 (Bad Request) Malformed request |
1729 | de2e08f6 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1730 | de2e08f6 | Stavros Sachtouris | 403 (Forbidden) Forbidden to use this flavor |
1731 | de2e08f6 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1732 | e7f266c3 | Stavros Sachtouris | \ internal error |
1733 | de2e08f6 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1734 | de2e08f6 | Stavros Sachtouris | =========================== ===================== |
1735 | de2e08f6 | Stavros Sachtouris | |
1736 | 2b9d64a5 | Stavros Sachtouris | Response code contents:: |
1737 | de2e08f6 | Stavros Sachtouris | |
1738 | 2b9d64a5 | Stavros Sachtouris | flavors: {values[ |
1739 | 2b9d64a5 | Stavros Sachtouris | { |
1740 | 2b9d64a5 | Stavros Sachtouris | <flavor attribute>: <value>, |
1741 | 2b9d64a5 | Stavros Sachtouris | ... |
1742 | 2b9d64a5 | Stavros Sachtouris | }, |
1743 | 2b9d64a5 | Stavros Sachtouris | ... |
1744 | 2b9d64a5 | Stavros Sachtouris | ]} |
1745 | de2e08f6 | Stavros Sachtouris | |
1746 | 2b9d64a5 | Stavros Sachtouris | Flavor attributes are `listed here <#flavor-ref>`_. Regular listing contains |
1747 | 2b9d64a5 | Stavros Sachtouris | only ``id`` and ``name`` attributes. |
1748 | 2cd1c00a | Giorgos Verigakis | |
1749 | 634ef3a8 | Stavros Sachtouris | *Example List Flavors (regular): JSON* |
1750 | de2e08f6 | Stavros Sachtouris | |
1751 | de2e08f6 | Stavros Sachtouris | .. code-block:: javascript |
1752 | de2e08f6 | Stavros Sachtouris | |
1753 | de2e08f6 | Stavros Sachtouris | { |
1754 | de2e08f6 | Stavros Sachtouris | "flavors": { |
1755 | de2e08f6 | Stavros Sachtouris | "values": [ |
1756 | de2e08f6 | Stavros Sachtouris | { |
1757 | de2e08f6 | Stavros Sachtouris | "id": 1, |
1758 | e74edfbb | Stavros Sachtouris | "name": "One code", |
1759 | de2e08f6 | Stavros Sachtouris | }, { |
1760 | de2e08f6 | Stavros Sachtouris | "id": 3, |
1761 | e74edfbb | Stavros Sachtouris | "name": "Four core", |
1762 | de2e08f6 | Stavros Sachtouris | } |
1763 | de2e08f6 | Stavros Sachtouris | ] |
1764 | de2e08f6 | Stavros Sachtouris | } |
1765 | de2e08f6 | Stavros Sachtouris | } |
1766 | de2e08f6 | Stavros Sachtouris | |
1767 | 2b9d64a5 | Stavros Sachtouris | |
1768 | 634ef3a8 | Stavros Sachtouris | *Example List Flavors (regular): XML* |
1769 | de2e08f6 | Stavros Sachtouris | |
1770 | de2e08f6 | Stavros Sachtouris | .. code-block:: xml |
1771 | de2e08f6 | Stavros Sachtouris | |
1772 | de2e08f6 | Stavros Sachtouris | <?xml version="1.0" encoding="UTF-8"?> |
1773 | de2e08f6 | Stavros Sachtouris | <flavors xmlns="http://docs.openstack.org/compute/api/v1" |
1774 | de2e08f6 | Stavros Sachtouris | xmlns:atom="http://www.w3.org/2005/Atom"> |
1775 | de2e08f6 | Stavros Sachtouris | <flavor id="1" name="One core"/> |
1776 | de2e08f6 | Stavros Sachtouris | <flavor id="3" name="Four core"/> |
1777 | de2e08f6 | Stavros Sachtouris | </flavors> |
1778 | de2e08f6 | Stavros Sachtouris | |
1779 | 634ef3a8 | Stavros Sachtouris | *Example List Flavors (detail): JSON* |
1780 | de2e08f6 | Stavros Sachtouris | |
1781 | de2e08f6 | Stavros Sachtouris | .. code-block:: javascript |
1782 | de2e08f6 | Stavros Sachtouris | |
1783 | de2e08f6 | Stavros Sachtouris | { |
1784 | de2e08f6 | Stavros Sachtouris | "flavors": { |
1785 | de2e08f6 | Stavros Sachtouris | "values": [ |
1786 | de2e08f6 | Stavros Sachtouris | { |
1787 | de2e08f6 | Stavros Sachtouris | "id": 1, |
1788 | de2e08f6 | Stavros Sachtouris | "name": "One core", |
1789 | de2e08f6 | Stavros Sachtouris | "ram": 1024, |
1790 | de2e08f6 | Stavros Sachtouris | "SNF:disk_template": "drbd", |
1791 | de2e08f6 | Stavros Sachtouris | "disk": 20, |
1792 | de2e08f6 | Stavros Sachtouris | "cpu": 1 |
1793 | de2e08f6 | Stavros Sachtouris | }, { |
1794 | de2e08f6 | Stavros Sachtouris | "id": 3, |
1795 | de2e08f6 | Stavros Sachtouris | "name": "Four core", |
1796 | de2e08f6 | Stavros Sachtouris | "ram": 1024, |
1797 | de2e08f6 | Stavros Sachtouris | "SNF:disk_template": "drbd", |
1798 | de2e08f6 | Stavros Sachtouris | "disk": 40, |
1799 | de2e08f6 | Stavros Sachtouris | "cpu": 4 |
1800 | de2e08f6 | Stavros Sachtouris | } |
1801 | de2e08f6 | Stavros Sachtouris | ] |
1802 | de2e08f6 | Stavros Sachtouris | } |
1803 | de2e08f6 | Stavros Sachtouris | } |
1804 | de2e08f6 | Stavros Sachtouris | |
1805 | 2b9d64a5 | Stavros Sachtouris | .. note:: In Compute OS API, the ``values`` layer is missing from the response |
1806 | 23a2f796 | Stavros Sachtouris | |
1807 | de2e08f6 | Stavros Sachtouris | Get Flavor Details |
1808 | de2e08f6 | Stavros Sachtouris | .................. |
1809 | de2e08f6 | Stavros Sachtouris | |
1810 | 2b9d64a5 | Stavros Sachtouris | Get the configuration of a specific flavor |
1811 | 2b9d64a5 | Stavros Sachtouris | |
1812 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Request |
1813 | 2b9d64a5 | Stavros Sachtouris | |
1814 | 23a2f796 | Stavros Sachtouris | ======================= ====== ======== ========== |
1815 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1816 | 23a2f796 | Stavros Sachtouris | ======================= ====== ======== ========== |
1817 | 23a2f796 | Stavros Sachtouris | ``/flavors/<flavor-id`` GET ✔ ✔ |
1818 | 23a2f796 | Stavros Sachtouris | ======================= ====== ======== ========== |
1819 | 23a2f796 | Stavros Sachtouris | |
1820 | 23a2f796 | Stavros Sachtouris | * **flavor-id** is the identifier of the flavor |
1821 | 23a2f796 | Stavros Sachtouris | |
1822 | 23a2f796 | Stavros Sachtouris | | |
1823 | 23a2f796 | Stavros Sachtouris | |
1824 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1825 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1826 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1827 | b38e8fa5 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1828 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1829 | 23a2f796 | Stavros Sachtouris | |
1830 | 23a2f796 | Stavros Sachtouris | | |
1831 | 23a2f796 | Stavros Sachtouris | |
1832 | 23a2f796 | Stavros Sachtouris | ================= =============== |
1833 | 3458183d | Constantinos Venetsanopoulos | Request Parameter Value |
1834 | 23a2f796 | Stavros Sachtouris | ================= =============== |
1835 | 23a2f796 | Stavros Sachtouris | json Respond in json |
1836 | 3458183d | Constantinos Venetsanopoulos | xml Respond in xml |
1837 | 23a2f796 | Stavros Sachtouris | ================= =============== |
1838 | 23a2f796 | Stavros Sachtouris | |
1839 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request body should be empty |
1840 | 2b9d64a5 | Stavros Sachtouris | |
1841 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Response |
1842 | 23a2f796 | Stavros Sachtouris | |
1843 | 23a2f796 | Stavros Sachtouris | =========================== ===================== |
1844 | 23a2f796 | Stavros Sachtouris | Return Code Description |
1845 | 23a2f796 | Stavros Sachtouris | =========================== ===================== |
1846 | 23a2f796 | Stavros Sachtouris | 200 (OK) Request succeeded |
1847 | 23a2f796 | Stavros Sachtouris | 400 (Bad Request) Malformed flavor ID |
1848 | 23a2f796 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1849 | 23a2f796 | Stavros Sachtouris | 403 (Forbidden) Forbidden to use this flavor |
1850 | 23a2f796 | Stavros Sachtouris | 404 (Not Found) Flavor id not founmd |
1851 | 23a2f796 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1852 | e7f266c3 | Stavros Sachtouris | \ internal error |
1853 | 23a2f796 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1854 | 23a2f796 | Stavros Sachtouris | =========================== ===================== |
1855 | 23a2f796 | Stavros Sachtouris | |
1856 | 2b9d64a5 | Stavros Sachtouris | Response code contents:: |
1857 | 23a2f796 | Stavros Sachtouris | |
1858 | 2b9d64a5 | Stavros Sachtouris | flavor: { |
1859 | 2b9d64a5 | Stavros Sachtouris | <flavor attribute>: <value>, |
1860 | 2b9d64a5 | Stavros Sachtouris | ... |
1861 | 2b9d64a5 | Stavros Sachtouris | } |
1862 | 2b9d64a5 | Stavros Sachtouris | |
1863 | 2b9d64a5 | Stavros Sachtouris | All flavor attributes are `listed here <flavor-ref>`_. |
1864 | 2b9d64a5 | Stavros Sachtouris | |
1865 | 634ef3a8 | Stavros Sachtouris | *Example Flavor Details: JSON* |
1866 | 23a2f796 | Stavros Sachtouris | |
1867 | 23a2f796 | Stavros Sachtouris | .. code-block:: javascript |
1868 | 3458183d | Constantinos Venetsanopoulos | |
1869 | 23a2f796 | Stavros Sachtouris | { |
1870 | 23a2f796 | Stavros Sachtouris | "flavor": { |
1871 | 23a2f796 | Stavros Sachtouris | { |
1872 | 23a2f796 | Stavros Sachtouris | "id": 1, |
1873 | 23a2f796 | Stavros Sachtouris | "name": "One core", |
1874 | 23a2f796 | Stavros Sachtouris | "ram": 1024, |
1875 | 23a2f796 | Stavros Sachtouris | "SNF:disk_template": "drbd", |
1876 | 23a2f796 | Stavros Sachtouris | "disk": 20, |
1877 | 23a2f796 | Stavros Sachtouris | "cpu": 1 |
1878 | 23a2f796 | Stavros Sachtouris | } |
1879 | 23a2f796 | Stavros Sachtouris | } |
1880 | 23a2f796 | Stavros Sachtouris | } |
1881 | 23a2f796 | Stavros Sachtouris | |
1882 | 634ef3a8 | Stavros Sachtouris | *Example Flavor Details: XML* |
1883 | 23a2f796 | Stavros Sachtouris | |
1884 | 23a2f796 | Stavros Sachtouris | .. code-block:: xml |
1885 | 23a2f796 | Stavros Sachtouris | |
1886 | 23a2f796 | Stavros Sachtouris | <?xml version="1.0" encoding="UTF-8"?> |
1887 | 23a2f796 | Stavros Sachtouris | <flavor xmlns="http://docs.openstack.org/compute/api/v1" |
1888 | 23a2f796 | Stavros Sachtouris | xmlns:atom="http://www.w3.org/2005/Atom" |
1889 | 23a2f796 | Stavros Sachtouris | id="1" name="One core" ram="1024" disk="20" cpu="1" /> |
1890 | 2cd1c00a | Giorgos Verigakis | |
1891 | 2cd1c00a | Giorgos Verigakis | Images |
1892 | 2cd1c00a | Giorgos Verigakis | ------ |
1893 | 2cd1c00a | Giorgos Verigakis | |
1894 | b38e8fa5 | Stavros Sachtouris | An image is a collection of files used to create or rebuild a server. Synnefo |
1895 | b38e8fa5 | Stavros Sachtouris | deployments usually provide pre-built OS images, but custom image creation is |
1896 | b38e8fa5 | Stavros Sachtouris | also supported. |
1897 | e74edfbb | Stavros Sachtouris | |
1898 | 1730a8b6 | Stavros Sachtouris | ============================================= ===================================== ====== ======== ========== |
1899 | 1730a8b6 | Stavros Sachtouris | Description URI Method Cyclades OS/Compute |
1900 | 1730a8b6 | Stavros Sachtouris | ============================================= ===================================== ====== ======== ========== |
1901 | 1730a8b6 | Stavros Sachtouris | `List <#list-images>`_ ``/images`` GET ✔ ✔ |
1902 | 1730a8b6 | Stavros Sachtouris | \ ``/images/detail`` GET ✔ ✔ |
1903 | 1730a8b6 | Stavros Sachtouris | `Get details <#get-image-details>`_ ``/images/<image-id>`` GET ✔ ✔ |
1904 | 1730a8b6 | Stavros Sachtouris | `Delete <#delete-image>`_ ``/images/<image id>`` DELETE ✔ ✔ |
1905 | 1730a8b6 | Stavros Sachtouris | `List Metadata <#list-image-metadata>`_ ``/images/<image-id>/meta`` GET ✔ **✘** |
1906 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata`` GET **✘** ✔ |
1907 | 1730a8b6 | Stavros Sachtouris | `Update Metadata <#update-image-metadata>`_ ``/images/<image-id>/meta`` POST ✔ **✘** |
1908 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata`` PUT **✘** ✔ |
1909 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata`` POST **✘** ✔ |
1910 | 1730a8b6 | Stavros Sachtouris | `Get Meta Item <#get-image-metadatum>`_ ``/image/<image-id>/meta/<key>`` GET ✔ **✘** |
1911 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata/<key>`` GET **✘** ✔ |
1912 | 1730a8b6 | Stavros Sachtouris | `Update Metadatum <#update-image-metadatum>`_ ``/images/<image-id>/meta/<key>`` PUT ✔ **✘** |
1913 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata/<key>`` PUT **✘** ✔ |
1914 | 1730a8b6 | Stavros Sachtouris | `Delete Metadatum <#delete-image-metadatum>`_ ``/images/<image-id>/meta/<key>`` DELETE ✔ **✘** |
1915 | 1730a8b6 | Stavros Sachtouris | \ ``/images/<image-id>/metadata/<key>`` DELETE **✘** ✔ |
1916 | 1730a8b6 | Stavros Sachtouris | ============================================= ===================================== ====== ======== ========== |
1917 | 1730a8b6 | Stavros Sachtouris | |
1918 | 1730a8b6 | Stavros Sachtouris | |
1919 | e74edfbb | Stavros Sachtouris | List Images |
1920 | e74edfbb | Stavros Sachtouris | ........... |
1921 | e74edfbb | Stavros Sachtouris | |
1922 | 2b9d64a5 | Stavros Sachtouris | List all images accessible by the user |
1923 | 2b9d64a5 | Stavros Sachtouris | |
1924 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Request |
1925 | 2b9d64a5 | Stavros Sachtouris | |
1926 | e74edfbb | Stavros Sachtouris | =================== ====== ======== ========== |
1927 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
1928 | e74edfbb | Stavros Sachtouris | =================== ====== ======== ========== |
1929 | b16e83ee | Stavros Sachtouris | ``/images`` GET ✔ ✔ |
1930 | b16e83ee | Stavros Sachtouris | ``/images/detail`` GET ✔ ✔ |
1931 | e74edfbb | Stavros Sachtouris | =================== ====== ======== ========== |
1932 | e74edfbb | Stavros Sachtouris | |
1933 | 2b9d64a5 | Stavros Sachtouris | | |
1934 | 2b9d64a5 | Stavros Sachtouris | |
1935 | 2b9d64a5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1936 | 2b9d64a5 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
1937 | 2b9d64a5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1938 | 2b9d64a5 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
1939 | 2b9d64a5 | Stavros Sachtouris | ============== ========================= ======== ========== |
1940 | e74edfbb | Stavros Sachtouris | |
1941 | e74edfbb | Stavros Sachtouris | | |
1942 | e74edfbb | Stavros Sachtouris | |
1943 | e74edfbb | Stavros Sachtouris | ================= ======================== ======== ========== |
1944 | 68386e00 | Stavros Sachtouris | Request Parameter Value Cyclades OS/Compute |
1945 | e74edfbb | Stavros Sachtouris | ================= ======================== ======== ========== |
1946 | e74edfbb | Stavros Sachtouris | server Server filter **✘** ✔ |
1947 | e74edfbb | Stavros Sachtouris | name Image name filter **✘** ✔ |
1948 | e74edfbb | Stavros Sachtouris | status Server status filter **✘** ✔ |
1949 | e74edfbb | Stavros Sachtouris | changes-since Change timestamp filter ✔ ✔ |
1950 | e74edfbb | Stavros Sachtouris | marker Last list last ID filter **✘** ✔ |
1951 | e74edfbb | Stavros Sachtouris | limit Page size filter **✘** ✔ |
1952 | e74edfbb | Stavros Sachtouris | type Request filter type **✘** ✔ |
1953 | e74edfbb | Stavros Sachtouris | ================= ======================== ======== ========== |
1954 | e74edfbb | Stavros Sachtouris | |
1955 | b38e8fa5 | Stavros Sachtouris | * **changes-since** must be an ISO8601 date string. In Cyclades it refers to |
1956 | b38e8fa5 | Stavros Sachtouris | the image ``updated_at`` attribute and it should be a date in the window |
1957 | b38e8fa5 | Stavros Sachtouris | [- POLL_LIMIT ... now]. POLL_LIMIT default value is 3600 seconds except if it |
1958 | b38e8fa5 | Stavros Sachtouris | is set otherwise at server side. |
1959 | e74edfbb | Stavros Sachtouris | |
1960 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request body should be empty |
1961 | e74edfbb | Stavros Sachtouris | |
1962 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Response |
1963 | e74edfbb | Stavros Sachtouris | |
1964 | e74edfbb | Stavros Sachtouris | =========================== ===================== |
1965 | e74edfbb | Stavros Sachtouris | Return Code Description |
1966 | e74edfbb | Stavros Sachtouris | =========================== ===================== |
1967 | e74edfbb | Stavros Sachtouris | 200 (OK) Request succeeded |
1968 | e74edfbb | Stavros Sachtouris | 304 (No images since date) Can be returned if ``changes-since`` is given |
1969 | e74edfbb | Stavros Sachtouris | 400 (Bad Request) Invalid or malformed ``changes-since`` parameter |
1970 | e74edfbb | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
1971 | e74edfbb | Stavros Sachtouris | 403 (Forbidden) User is not allowed to perform this operation |
1972 | e74edfbb | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
1973 | e7f266c3 | Stavros Sachtouris | \ internal error |
1974 | e74edfbb | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
1975 | e74edfbb | Stavros Sachtouris | =========================== ===================== |
1976 | e74edfbb | Stavros Sachtouris | |
1977 | 2b9d64a5 | Stavros Sachtouris | Response body contents:: |
1978 | b38e8fa5 | Stavros Sachtouris | |
1979 | 2b9d64a5 | Stavros Sachtouris | images: {values: [ |
1980 | 2b9d64a5 | Stavros Sachtouris | { |
1981 | 2b9d64a5 | Stavros Sachtouris | <image attribute>: <value>, |
1982 | 2b9d64a5 | Stavros Sachtouris | ... |
1983 | 2b9d64a5 | Stavros Sachtouris | metadata: {values: { |
1984 | 2b9d64a5 | Stavros Sachtouris | <image metadatum key>: <value>, |
1985 | 2b9d64a5 | Stavros Sachtouris | ... |
1986 | 2b9d64a5 | Stavros Sachtouris | }}, |
1987 | 2b9d64a5 | Stavros Sachtouris | ... |
1988 | 2b9d64a5 | Stavros Sachtouris | }, |
1989 | 2b9d64a5 | Stavros Sachtouris | ... |
1990 | 2b9d64a5 | Stavros Sachtouris | ]} |
1991 | 2b9d64a5 | Stavros Sachtouris | |
1992 | 2b9d64a5 | Stavros Sachtouris | The regular response returns just ``id`` and ``name``, while the detail returns a collections of the `image attributes listed here <#image-ref>`_. |
1993 | e74edfbb | Stavros Sachtouris | |
1994 | 634ef3a8 | Stavros Sachtouris | *Example List Image (detail): JSON* |
1995 | e74edfbb | Stavros Sachtouris | |
1996 | e74edfbb | Stavros Sachtouris | .. code-block:: javascript |
1997 | e74edfbb | Stavros Sachtouris | |
1998 | e74edfbb | Stavros Sachtouris | { |
1999 | e74edfbb | Stavros Sachtouris | "images: { |
2000 | e74edfbb | Stavros Sachtouris | "values": [ |
2001 | e74edfbb | Stavros Sachtouris | { |
2002 | e74edfbb | Stavros Sachtouris | "status": "ACTIVE", |
2003 | e74edfbb | Stavros Sachtouris | "updated": "2013-03-02T15:57:03+00:00", |
2004 | e74edfbb | Stavros Sachtouris | "name": "edx_saas", |
2005 | e74edfbb | Stavros Sachtouris | "created": "2013-03-02T12:21:00+00:00", |
2006 | e74edfbb | Stavros Sachtouris | "progress": 100, |
2007 | e74edfbb | Stavros Sachtouris | "id": "175716...526236", |
2008 | e74edfbb | Stavros Sachtouris | "metadata": { |
2009 | e74edfbb | Stavros Sachtouris | "values": { |
2010 | e74edfbb | Stavros Sachtouris | "partition_table": "msdos", |
2011 | e74edfbb | Stavros Sachtouris | "osfamily": "linux", |
2012 | e74edfbb | Stavros Sachtouris | "users": "root saasbook", |
2013 | e74edfbb | Stavros Sachtouris | "exclude_task_changepassword": "yes", |
2014 | e74edfbb | Stavros Sachtouris | "os": "ubuntu", |
2015 | e74edfbb | Stavros Sachtouris | "root_partition": "1", |
2016 | e74edfbb | Stavros Sachtouris | "description": "Ubuntu 12.04 LTS" |
2017 | e74edfbb | Stavros Sachtouris | } |
2018 | e74edfbb | Stavros Sachtouris | } |
2019 | e74edfbb | Stavros Sachtouris | }, { |
2020 | e74edfbb | Stavros Sachtouris | "status": "ACTIVE", |
2021 | e74edfbb | Stavros Sachtouris | "updated": "2013-03-02T15:57:03+00:00", |
2022 | e74edfbb | Stavros Sachtouris | "name": "edx_saas", |
2023 | e74edfbb | Stavros Sachtouris | "created": "2013-03-02T12:21:00+00:00", |
2024 | e74edfbb | Stavros Sachtouris | "progress": 100, |
2025 | e74edfbb | Stavros Sachtouris | "id": "1357163d...c526206", |
2026 | e74edfbb | Stavros Sachtouris | "metadata": { |
2027 | e74edfbb | Stavros Sachtouris | "values": { |
2028 | e74edfbb | Stavros Sachtouris | "partition_table": "msdos", |
2029 | e74edfbb | Stavros Sachtouris | "osfamily": "windows", |
2030 | e74edfbb | Stavros Sachtouris | "users": "Administratior", |
2031 | e74edfbb | Stavros Sachtouris | "exclude_task_changepassword": "yes", |
2032 | e74edfbb | Stavros Sachtouris | "os": "WinME", |
2033 | e74edfbb | Stavros Sachtouris | "root_partition": "1", |
2034 | e74edfbb | Stavros Sachtouris | "description": "Rerto Windows" |
2035 | e74edfbb | Stavros Sachtouris | } |
2036 | e74edfbb | Stavros Sachtouris | } |
2037 | e74edfbb | Stavros Sachtouris | } |
2038 | e74edfbb | Stavros Sachtouris | ] |
2039 | e74edfbb | Stavros Sachtouris | } |
2040 | e74edfbb | Stavros Sachtouris | } |
2041 | e74edfbb | Stavros Sachtouris | |
2042 | 2b9d64a5 | Stavros Sachtouris | .. note:: In Compute OS API, the ``values`` layer is missing from the response |
2043 | e74edfbb | Stavros Sachtouris | |
2044 | f76ec11f | Stavros Sachtouris | Get Image Details |
2045 | f76ec11f | Stavros Sachtouris | ................. |
2046 | f76ec11f | Stavros Sachtouris | |
2047 | 2b9d64a5 | Stavros Sachtouris | Get the details of a specific image |
2048 | 2b9d64a5 | Stavros Sachtouris | |
2049 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Request |
2050 | 2b9d64a5 | Stavros Sachtouris | |
2051 | f76ec11f | Stavros Sachtouris | ====================== ====== ======== ========== |
2052 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2053 | f76ec11f | Stavros Sachtouris | ====================== ====== ======== ========== |
2054 | f76ec11f | Stavros Sachtouris | ``/images/<image-id>`` GET ✔ ✔ |
2055 | f76ec11f | Stavros Sachtouris | ====================== ====== ======== ========== |
2056 | f76ec11f | Stavros Sachtouris | |
2057 | f76ec11f | Stavros Sachtouris | * **image-id** is the identifier of the virtual image |
2058 | f76ec11f | Stavros Sachtouris | |
2059 | f76ec11f | Stavros Sachtouris | | |
2060 | f76ec11f | Stavros Sachtouris | |
2061 | f76ec11f | Stavros Sachtouris | ============== ========================= ======== ========== |
2062 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2063 | f76ec11f | Stavros Sachtouris | ============== ========================= ======== ========== |
2064 | f76ec11f | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2065 | f76ec11f | Stavros Sachtouris | ============== ========================= ======== ========== |
2066 | f76ec11f | Stavros Sachtouris | |
2067 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2068 | 2b9d64a5 | Stavros Sachtouris | |
2069 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request body should be empty |
2070 | 2b9d64a5 | Stavros Sachtouris | |
2071 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Response |
2072 | f76ec11f | Stavros Sachtouris | |
2073 | f76ec11f | Stavros Sachtouris | =========================== ===================== |
2074 | f76ec11f | Stavros Sachtouris | Return Code Description |
2075 | f76ec11f | Stavros Sachtouris | =========================== ===================== |
2076 | f76ec11f | Stavros Sachtouris | 200 (OK) Request succeeded |
2077 | f76ec11f | Stavros Sachtouris | 400 (Bad Request) Malformed image id |
2078 | f76ec11f | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2079 | f76ec11f | Stavros Sachtouris | 403 (Forbidden) Not allowed to use this image |
2080 | f76ec11f | Stavros Sachtouris | 404 (Not Found) Image not found |
2081 | f76ec11f | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2082 | e7f266c3 | Stavros Sachtouris | \ internal error |
2083 | f76ec11f | Stavros Sachtouris | 503 (Service Unavailable) No available backends or service currently |
2084 | e7f266c3 | Stavros Sachtouris | \ unavailable |
2085 | f76ec11f | Stavros Sachtouris | =========================== ===================== |
2086 | f76ec11f | Stavros Sachtouris | |
2087 | 2b9d64a5 | Stavros Sachtouris | Response body contents:: |
2088 | f76ec11f | Stavros Sachtouris | |
2089 | 2b9d64a5 | Stavros Sachtouris | image: { |
2090 | 2b9d64a5 | Stavros Sachtouris | <image attribute>: <value>, |
2091 | 2b9d64a5 | Stavros Sachtouris | ... |
2092 | 2b9d64a5 | Stavros Sachtouris | metadata: {values:{ |
2093 | 2b9d64a5 | Stavros Sachtouris | <image metadatum key>: <value> |
2094 | 2b9d64a5 | Stavros Sachtouris | }} |
2095 | 2b9d64a5 | Stavros Sachtouris | } |
2096 | f76ec11f | Stavros Sachtouris | |
2097 | 2b9d64a5 | Stavros Sachtouris | Image attributes are `listed here <#image-ref>`_. |
2098 | f76ec11f | Stavros Sachtouris | |
2099 | 634ef3a8 | Stavros Sachtouris | *Example Details for an image with id 6404619d-...-aef57eaff4af, in JSON* |
2100 | f76ec11f | Stavros Sachtouris | |
2101 | f76ec11f | Stavros Sachtouris | .. code-block:: javascript |
2102 | f76ec11f | Stavros Sachtouris | |
2103 | f76ec11f | Stavros Sachtouris | { |
2104 | f76ec11f | Stavros Sachtouris | "image": { |
2105 | f76ec11f | Stavros Sachtouris | "id": "6404619d-...-aef57eaff4af", |
2106 | f76ec11f | Stavros Sachtouris | "name": "FreeBSD", |
2107 | f76ec11f | Stavros Sachtouris | "status": "ACTIVE", |
2108 | f76ec11f | Stavros Sachtouris | "updated": "2013-04-24T12:06:02+00:00", |
2109 | f76ec11f | Stavros Sachtouris | "created": "2013-04-24T11:52:16+00:00", |
2110 | f76ec11f | Stavros Sachtouris | "progress": 100, |
2111 | f76ec11f | Stavros Sachtouris | "metadata": { |
2112 | f76ec11f | Stavros Sachtouris | "values": { |
2113 | f76ec11f | Stavros Sachtouris | "kernel": "9.1 RELEASE", |
2114 | f76ec11f | Stavros Sachtouris | "osfamily": "freebsd", |
2115 | f76ec11f | Stavros Sachtouris | "users": "root", |
2116 | f76ec11f | Stavros Sachtouris | "gui": "No GUI", |
2117 | f76ec11f | Stavros Sachtouris | "sortorder": "9", |
2118 | f76ec11f | Stavros Sachtouris | "os": "freebsd", |
2119 | f76ec11f | Stavros Sachtouris | "root_partition": "2", |
2120 | f76ec11f | Stavros Sachtouris | "description": "FreeBSD 9" |
2121 | f76ec11f | Stavros Sachtouris | } |
2122 | f76ec11f | Stavros Sachtouris | } |
2123 | f76ec11f | Stavros Sachtouris | } |
2124 | f76ec11f | Stavros Sachtouris | } |
2125 | e74edfbb | Stavros Sachtouris | |
2126 | 348bdb4e | Stavros Sachtouris | .. note:: In OS/Compute API, the ``values`` layer is missing. |
2127 | 2b9d64a5 | Stavros Sachtouris | |
2128 | e74edfbb | Stavros Sachtouris | |
2129 | 9169cde6 | Stavros Sachtouris | Delete Image |
2130 | 9169cde6 | Stavros Sachtouris | ............ |
2131 | 9169cde6 | Stavros Sachtouris | |
2132 | 2b9d64a5 | Stavros Sachtouris | Delete an image, by changing its status from ``ACTIVE`` to ``DELETED``. |
2133 | 2b9d64a5 | Stavros Sachtouris | |
2134 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Request |
2135 | 2b9d64a5 | Stavros Sachtouris | |
2136 | 348bdb4e | Stavros Sachtouris | ====================== ====== ======== ========== |
2137 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2138 | 348bdb4e | Stavros Sachtouris | ====================== ====== ======== ========== |
2139 | 9169cde6 | Stavros Sachtouris | ``/images/<image id>`` DELETE ✔ ✔ |
2140 | 9169cde6 | Stavros Sachtouris | ====================== ====== ======== ========== |
2141 | 9169cde6 | Stavros Sachtouris | |
2142 | 2b9d64a5 | Stavros Sachtouris | * **image id** is the identifier of the image |
2143 | 9169cde6 | Stavros Sachtouris | |
2144 | 9169cde6 | Stavros Sachtouris | | |
2145 | 9169cde6 | Stavros Sachtouris | |
2146 | 9169cde6 | Stavros Sachtouris | ============== ========================= ======== ========== |
2147 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2148 | 9169cde6 | Stavros Sachtouris | ============== ========================= ======== ========== |
2149 | 9169cde6 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2150 | 9169cde6 | Stavros Sachtouris | ============== ========================= ======== ========== |
2151 | 9169cde6 | Stavros Sachtouris | |
2152 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2153 | 2b9d64a5 | Stavros Sachtouris | |
2154 | 2b9d64a5 | Stavros Sachtouris | .. note:: Request body should be empty |
2155 | 2b9d64a5 | Stavros Sachtouris | |
2156 | 2b9d64a5 | Stavros Sachtouris | .. rubric:: Response |
2157 | 9169cde6 | Stavros Sachtouris | |
2158 | 9169cde6 | Stavros Sachtouris | =========================== ===================== |
2159 | 9169cde6 | Stavros Sachtouris | Return Code Description |
2160 | 9169cde6 | Stavros Sachtouris | =========================== ===================== |
2161 | 9169cde6 | Stavros Sachtouris | 204 (OK) Request succeeded |
2162 | 9169cde6 | Stavros Sachtouris | 400 (Bad Request) Invalid request or image id |
2163 | 9169cde6 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2164 | 9169cde6 | Stavros Sachtouris | 404 (Not Found) Image not found |
2165 | 9169cde6 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2166 | e7f266c3 | Stavros Sachtouris | \ internal error |
2167 | 9169cde6 | Stavros Sachtouris | 503 (Service Unavailable) Action not supported or service currently |
2168 | e7f266c3 | Stavros Sachtouris | \ unavailable |
2169 | 9169cde6 | Stavros Sachtouris | =========================== ===================== |
2170 | 9169cde6 | Stavros Sachtouris | |
2171 | 2b9d64a5 | Stavros Sachtouris | .. note:: In case of a 204 code, request body should be empty |
2172 | b38e8fa5 | Stavros Sachtouris | |
2173 | 03c9cb80 | Stavros Sachtouris | List Image Metadata |
2174 | 03c9cb80 | Stavros Sachtouris | ................... |
2175 | c347ba83 | Stavros Sachtouris | |
2176 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
2177 | 68386e00 | Stavros Sachtouris | besides the different URI. |
2178 | c347ba83 | Stavros Sachtouris | |
2179 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Request |
2180 | 03c9cb80 | Stavros Sachtouris | |
2181 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2182 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2183 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2184 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/meta`` GET ✔ **✘** |
2185 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/metadata`` GET **✘** ✔ |
2186 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2187 | c347ba83 | Stavros Sachtouris | |
2188 | c347ba83 | Stavros Sachtouris | * **image-id** is the identifier of the virtual image |
2189 | c347ba83 | Stavros Sachtouris | |
2190 | c347ba83 | Stavros Sachtouris | | |
2191 | c347ba83 | Stavros Sachtouris | |
2192 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2193 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2194 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2195 | c347ba83 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2196 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2197 | c347ba83 | Stavros Sachtouris | |
2198 | 03c9cb80 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2199 | 03c9cb80 | Stavros Sachtouris | |
2200 | 03c9cb80 | Stavros Sachtouris | .. note:: Request body should be empty |
2201 | 03c9cb80 | Stavros Sachtouris | |
2202 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Response |
2203 | c347ba83 | Stavros Sachtouris | |
2204 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2205 | c347ba83 | Stavros Sachtouris | Return Code Description |
2206 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2207 | c347ba83 | Stavros Sachtouris | 201 (OK) Request succeeded |
2208 | c347ba83 | Stavros Sachtouris | 400 (Bad Request) Invalid image ID or Malformed request |
2209 | c347ba83 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2210 | c347ba83 | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
2211 | c347ba83 | Stavros Sachtouris | 404 (Not Found) Server not found |
2212 | c347ba83 | Stavros Sachtouris | 409 (Build In Progress) The image is not ready yet |
2213 | c347ba83 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2214 | e7f266c3 | Stavros Sachtouris | \ internal error |
2215 | c347ba83 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
2216 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2217 | c347ba83 | Stavros Sachtouris | |
2218 | 03c9cb80 | Stavros Sachtouris | Response body content:: |
2219 | 03c9cb80 | Stavros Sachtouris | |
2220 | 03c9cb80 | Stavros Sachtouris | metadata: { |
2221 | 03c9cb80 | Stavros Sachtouris | values: { |
2222 | 03c9cb80 | Stavros Sachtouris | <metadatum key>: <value>, |
2223 | 03c9cb80 | Stavros Sachtouris | ... |
2224 | 03c9cb80 | Stavros Sachtouris | } |
2225 | 03c9cb80 | Stavros Sachtouris | } |
2226 | 03c9cb80 | Stavros Sachtouris | |
2227 | 634ef3a8 | Stavros Sachtouris | *Example List Image Metadata: JSON* |
2228 | e74edfbb | Stavros Sachtouris | |
2229 | c347ba83 | Stavros Sachtouris | .. code-block:: javascript |
2230 | e74edfbb | Stavros Sachtouris | |
2231 | 3458183d | Constantinos Venetsanopoulos | { |
2232 | 68386e00 | Stavros Sachtouris | "metadata": { |
2233 | 68386e00 | Stavros Sachtouris | "values": { |
2234 | c347ba83 | Stavros Sachtouris | "partition_table": "msdos", |
2235 | c347ba83 | Stavros Sachtouris | "kernel": "3.2.0", |
2236 | c347ba83 | Stavros Sachtouris | "osfamily": "linux", |
2237 | c347ba83 | Stavros Sachtouris | "users": "user", |
2238 | c347ba83 | Stavros Sachtouris | "gui": "Unity 5", |
2239 | c347ba83 | Stavros Sachtouris | "sortorder": "3", |
2240 | c347ba83 | Stavros Sachtouris | "os": "ubuntu", |
2241 | c347ba83 | Stavros Sachtouris | "root_partition": "1", |
2242 | c347ba83 | Stavros Sachtouris | "description": "Ubuntu 12 LTS" |
2243 | c347ba83 | Stavros Sachtouris | } |
2244 | c347ba83 | Stavros Sachtouris | } |
2245 | c347ba83 | Stavros Sachtouris | } |
2246 | c347ba83 | Stavros Sachtouris | |
2247 | 03c9cb80 | Stavros Sachtouris | .. note:: In OS/Compute API the ``values`` level is missing from the response. |
2248 | c347ba83 | Stavros Sachtouris | |
2249 | 1730a8b6 | Stavros Sachtouris | Update Image Metadata |
2250 | 1730a8b6 | Stavros Sachtouris | ..................... |
2251 | c347ba83 | Stavros Sachtouris | |
2252 | c347ba83 | Stavros Sachtouris | In Cyclades API, setting new metadata and updating the values of existing ones |
2253 | 03c9cb80 | Stavros Sachtouris | is achieved using one type of request (POST), while in OS/Compute API two |
2254 | 03c9cb80 | Stavros Sachtouris | different types are used (PUT and POST for |
2255 | c347ba83 | Stavros Sachtouris | `setting new <http://docs.openstack.org/api/openstack-compute/2/content/Create_or_Replace_Metadata-d1e5358.html>`_ |
2256 | c347ba83 | Stavros Sachtouris | and |
2257 | c347ba83 | Stavros Sachtouris | `updating existing <http://docs.openstack.org/api/openstack-compute/2/content/Update_Metadata-d1e5208.html>`_ |
2258 | c347ba83 | Stavros Sachtouris | metadata, respectively). |
2259 | c347ba83 | Stavros Sachtouris | |
2260 | b38e8fa5 | Stavros Sachtouris | In Cyclades API, unmentioned metadata keys will remain intact, while metadata |
2261 | b38e8fa5 | Stavros Sachtouris | referred by the operation will be overwritten. |
2262 | c347ba83 | Stavros Sachtouris | |
2263 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Request |
2264 | 03c9cb80 | Stavros Sachtouris | |
2265 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2266 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2267 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2268 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/meta`` POST ✔ **✘** |
2269 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/metadata`` PUT **✘** ✔ |
2270 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/metadata`` POST **✘** ✔ |
2271 | c347ba83 | Stavros Sachtouris | =============================== ====== ======== ========== |
2272 | c347ba83 | Stavros Sachtouris | |
2273 | c347ba83 | Stavros Sachtouris | * **image-id** is the identifier of the virtual image |
2274 | c347ba83 | Stavros Sachtouris | |
2275 | c347ba83 | Stavros Sachtouris | | |
2276 | c347ba83 | Stavros Sachtouris | |
2277 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2278 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2279 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2280 | c347ba83 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2281 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
2282 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
2283 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2284 | c347ba83 | Stavros Sachtouris | |
2285 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
2286 | 634ef3a8 | Stavros Sachtouris | |
2287 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
2288 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
2289 | 634ef3a8 | Stavros Sachtouris | Content-Length: 52 |
2290 | 634ef3a8 | Stavros Sachtouris | |
2291 | 03c9cb80 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2292 | 03c9cb80 | Stavros Sachtouris | |
2293 | 03c9cb80 | Stavros Sachtouris | Request body content:: |
2294 | 03c9cb80 | Stavros Sachtouris | |
2295 | 03c9cb80 | Stavros Sachtouris | metadata: { |
2296 | 03c9cb80 | Stavros Sachtouris | <metadatum key>: <value>, |
2297 | 03c9cb80 | Stavros Sachtouris | ... |
2298 | 03c9cb80 | Stavros Sachtouris | } |
2299 | c347ba83 | Stavros Sachtouris | |
2300 | 634ef3a8 | Stavros Sachtouris | *Example Update Image Metadata Request: JSON* |
2301 | c347ba83 | Stavros Sachtouris | |
2302 | 03c9cb80 | Stavros Sachtouris | .. code-block:: javascript |
2303 | c347ba83 | Stavros Sachtouris | |
2304 | 03c9cb80 | Stavros Sachtouris | {"metadata": {"NewAttr": "NewVal", "os": "Xubuntu'}} |
2305 | 03c9cb80 | Stavros Sachtouris | |
2306 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Response |
2307 | c347ba83 | Stavros Sachtouris | |
2308 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2309 | c347ba83 | Stavros Sachtouris | Return Code Description |
2310 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2311 | c347ba83 | Stavros Sachtouris | 201 (OK) Request succeeded |
2312 | c347ba83 | Stavros Sachtouris | 400 (Bad Request) Malformed request or image id |
2313 | c347ba83 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2314 | c347ba83 | Stavros Sachtouris | 403 (Forbidden) Not allowed to modify this image |
2315 | c347ba83 | Stavros Sachtouris | 404 (Not Found) Image or metadatum key not found |
2316 | c347ba83 | Stavros Sachtouris | 413 (OverLimit) Maximum number of metadata exceeded |
2317 | c347ba83 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2318 | e7f266c3 | Stavros Sachtouris | \ internal error |
2319 | c347ba83 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
2320 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2321 | c347ba83 | Stavros Sachtouris | |
2322 | 03c9cb80 | Stavros Sachtouris | Response body content:: |
2323 | c347ba83 | Stavros Sachtouris | |
2324 | 03c9cb80 | Stavros Sachtouris | metadata: { |
2325 | 03c9cb80 | Stavros Sachtouris | <metadatum key>: <value>, |
2326 | 03c9cb80 | Stavros Sachtouris | ... |
2327 | 03c9cb80 | Stavros Sachtouris | } |
2328 | 03c9cb80 | Stavros Sachtouris | |
2329 | 634ef3a8 | Stavros Sachtouris | *Example Update Image Response: JSON* |
2330 | 03c9cb80 | Stavros Sachtouris | |
2331 | 03c9cb80 | Stavros Sachtouris | .. code-block:: javascript |
2332 | c347ba83 | Stavros Sachtouris | |
2333 | 3458183d | Constantinos Venetsanopoulos | { |
2334 | 03c9cb80 | Stavros Sachtouris | "metadata": { |
2335 | c347ba83 | Stavros Sachtouris | "partition_table": "msdos", |
2336 | c347ba83 | Stavros Sachtouris | "kernel": "3.2.0", |
2337 | c347ba83 | Stavros Sachtouris | "osfamily": "linux", |
2338 | c347ba83 | Stavros Sachtouris | "users": "user", |
2339 | c347ba83 | Stavros Sachtouris | "gui": "Unity 5", |
2340 | c347ba83 | Stavros Sachtouris | "sortorder": "3", |
2341 | c347ba83 | Stavros Sachtouris | "os": "Xubuntu", |
2342 | c347ba83 | Stavros Sachtouris | "root_partition": "1", |
2343 | c347ba83 | Stavros Sachtouris | "description": "Ubuntu 12 LTS", |
2344 | 03c9cb80 | Stavros Sachtouris | "NewAttr": "NewVal" |
2345 | c347ba83 | Stavros Sachtouris | } |
2346 | c347ba83 | Stavros Sachtouris | } |
2347 | c347ba83 | Stavros Sachtouris | |
2348 | 1730a8b6 | Stavros Sachtouris | Get Image Metadatum |
2349 | 1730a8b6 | Stavros Sachtouris | ................... |
2350 | c347ba83 | Stavros Sachtouris | |
2351 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
2352 | 68386e00 | Stavros Sachtouris | besides the different URI. |
2353 | c347ba83 | Stavros Sachtouris | |
2354 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Request |
2355 | 03c9cb80 | Stavros Sachtouris | |
2356 | c347ba83 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2357 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2358 | c347ba83 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2359 | c347ba83 | Stavros Sachtouris | ``/image/<image-id>/meta/<key>`` GET ✔ **✘** |
2360 | c347ba83 | Stavros Sachtouris | ``/images/<image-id>/metadata/<key>`` GET **✘** ✔ |
2361 | c347ba83 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2362 | c347ba83 | Stavros Sachtouris | |
2363 | b38e8fa5 | Stavros Sachtouris | * **image-id** is the identifier of the image |
2364 | b38e8fa5 | Stavros Sachtouris | |
2365 | c347ba83 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
2366 | c347ba83 | Stavros Sachtouris | |
2367 | c347ba83 | Stavros Sachtouris | | |
2368 | c347ba83 | Stavros Sachtouris | |
2369 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2370 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2371 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2372 | c347ba83 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2373 | c347ba83 | Stavros Sachtouris | ============== ========================= ======== ========== |
2374 | c347ba83 | Stavros Sachtouris | |
2375 | 03c9cb80 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2376 | 03c9cb80 | Stavros Sachtouris | |
2377 | 03c9cb80 | Stavros Sachtouris | .. note:: Request body should be empty |
2378 | 03c9cb80 | Stavros Sachtouris | |
2379 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Response |
2380 | c347ba83 | Stavros Sachtouris | |
2381 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2382 | c347ba83 | Stavros Sachtouris | Return Code Description |
2383 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2384 | c347ba83 | Stavros Sachtouris | 200 (OK) Request succeeded |
2385 | c347ba83 | Stavros Sachtouris | 400 (Bad Request) Malformed request or image id |
2386 | c347ba83 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2387 | c347ba83 | Stavros Sachtouris | 403 (Forbidden) Not allowed to access this information |
2388 | c347ba83 | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
2389 | c347ba83 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2390 | e7f266c3 | Stavros Sachtouris | \ internal error |
2391 | c347ba83 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
2392 | c347ba83 | Stavros Sachtouris | =========================== ===================== |
2393 | c347ba83 | Stavros Sachtouris | |
2394 | 03c9cb80 | Stavros Sachtouris | Response body content:: |
2395 | 03c9cb80 | Stavros Sachtouris | |
2396 | 03c9cb80 | Stavros Sachtouris | metadata: {<metadatum key>: <value>} |
2397 | 03c9cb80 | Stavros Sachtouris | |
2398 | 634ef3a8 | Stavros Sachtouris | *Example Get Image Metadatum Item: JSON* |
2399 | b38e8fa5 | Stavros Sachtouris | |
2400 | b38e8fa5 | Stavros Sachtouris | .. code-block:: javascript |
2401 | c347ba83 | Stavros Sachtouris | |
2402 | 68386e00 | Stavros Sachtouris | {"metadata": {"os": "Xubuntu"}} |
2403 | c347ba83 | Stavros Sachtouris | |
2404 | 68386e00 | Stavros Sachtouris | .. note:: In OS/Compute, ``metadata`` is ``meta`` |
2405 | c347ba83 | Stavros Sachtouris | |
2406 | 1730a8b6 | Stavros Sachtouris | Update Image Metadatum |
2407 | 1730a8b6 | Stavros Sachtouris | ...................... |
2408 | 0ad49876 | Stavros Sachtouris | |
2409 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
2410 | 68386e00 | Stavros Sachtouris | besides the different URI. |
2411 | 0ad49876 | Stavros Sachtouris | |
2412 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Request |
2413 | 03c9cb80 | Stavros Sachtouris | |
2414 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2415 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2416 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2417 | 0ad49876 | Stavros Sachtouris | ``/images/<image-id>/meta/<key>`` PUT ✔ **✘** |
2418 | 0ad49876 | Stavros Sachtouris | ``/images/<image-id>/metadata/<key>`` PUT **✘** ✔ |
2419 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2420 | 0ad49876 | Stavros Sachtouris | |
2421 | 0ad49876 | Stavros Sachtouris | * **image-id** is the identifier of the image |
2422 | b38e8fa5 | Stavros Sachtouris | |
2423 | 0ad49876 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
2424 | 0ad49876 | Stavros Sachtouris | |
2425 | 0ad49876 | Stavros Sachtouris | | |
2426 | 0ad49876 | Stavros Sachtouris | |
2427 | 0ad49876 | Stavros Sachtouris | ============== ========================= ======== ========== |
2428 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2429 | 0ad49876 | Stavros Sachtouris | ============== ========================= ======== ========== |
2430 | 0ad49876 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2431 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body required required |
2432 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body required required |
2433 | 0ad49876 | Stavros Sachtouris | ============== ========================= ======== ========== |
2434 | 0ad49876 | Stavros Sachtouris | |
2435 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
2436 | 634ef3a8 | Stavros Sachtouris | |
2437 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
2438 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
2439 | 634ef3a8 | Stavros Sachtouris | Content-Length: 27 |
2440 | 634ef3a8 | Stavros Sachtouris | |
2441 | 0ad49876 | Stavros Sachtouris | | |
2442 | 0ad49876 | Stavros Sachtouris | |
2443 | 03c9cb80 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2444 | 0ad49876 | Stavros Sachtouris | |
2445 | 03c9cb80 | Stavros Sachtouris | Request body content:: |
2446 | 0ad49876 | Stavros Sachtouris | |
2447 | 03c9cb80 | Stavros Sachtouris | meta: {<metadatum key>: <value>} |
2448 | 03c9cb80 | Stavros Sachtouris | |
2449 | 634ef3a8 | Stavros Sachtouris | *Example Update Image Metadatum Item Request: JSON* |
2450 | 03c9cb80 | Stavros Sachtouris | |
2451 | 03c9cb80 | Stavros Sachtouris | .. code-block:: javascript |
2452 | 03c9cb80 | Stavros Sachtouris | |
2453 | 03c9cb80 | Stavros Sachtouris | {"meta": {"os": "Kubuntu"}} |
2454 | 03c9cb80 | Stavros Sachtouris | |
2455 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Response |
2456 | 0ad49876 | Stavros Sachtouris | |
2457 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2458 | 0ad49876 | Stavros Sachtouris | Return Code Description |
2459 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2460 | 0ad49876 | Stavros Sachtouris | 201 (OK) Request succeeded |
2461 | 0ad49876 | Stavros Sachtouris | 400 (Bad Request) Malformed request or image id |
2462 | 0ad49876 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2463 | 0ad49876 | Stavros Sachtouris | 403 (Forbidden) Not allowed to modify this image |
2464 | 0ad49876 | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
2465 | 0ad49876 | Stavros Sachtouris | 413 (OverLimit) Maximum number of metadata exceeded |
2466 | 0ad49876 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2467 | e7f266c3 | Stavros Sachtouris | \ internal error |
2468 | 0ad49876 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
2469 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2470 | 0ad49876 | Stavros Sachtouris | |
2471 | 03c9cb80 | Stavros Sachtouris | Request body content:: |
2472 | 0ad49876 | Stavros Sachtouris | |
2473 | 03c9cb80 | Stavros Sachtouris | meta: {<metadatum key>: <value>} |
2474 | 0ad49876 | Stavros Sachtouris | |
2475 | 634ef3a8 | Stavros Sachtouris | *Example Update Image Metadatum Item Response: JSON* |
2476 | 03c9cb80 | Stavros Sachtouris | |
2477 | 03c9cb80 | Stavros Sachtouris | .. code-block:: javascript |
2478 | 03c9cb80 | Stavros Sachtouris | |
2479 | 03c9cb80 | Stavros Sachtouris | {"meta": {"os": "Kubuntu"}} |
2480 | 03c9cb80 | Stavros Sachtouris | |
2481 | 03c9cb80 | Stavros Sachtouris | Delete Image Metadatum |
2482 | 03c9cb80 | Stavros Sachtouris | ...................... |
2483 | 03c9cb80 | Stavros Sachtouris | |
2484 | 03c9cb80 | Stavros Sachtouris | Delete an image metadatum by its key. |
2485 | 0ad49876 | Stavros Sachtouris | |
2486 | 68386e00 | Stavros Sachtouris | .. note:: This operation is semantically equivalent in Cyclades and OS/Compute |
2487 | 68386e00 | Stavros Sachtouris | besides the different URI. |
2488 | 0ad49876 | Stavros Sachtouris | |
2489 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Request |
2490 | 03c9cb80 | Stavros Sachtouris | |
2491 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2492 | 68386e00 | Stavros Sachtouris | URI Method Cyclades OS/Compute |
2493 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2494 | 0ad49876 | Stavros Sachtouris | ``/images/<image-id>/meta/<key>`` DELETE ✔ **✘** |
2495 | 0ad49876 | Stavros Sachtouris | ``/images/<image-id>/metadata/<key>`` DELETE **✘** ✔ |
2496 | 0ad49876 | Stavros Sachtouris | ===================================== ====== ======== ========== |
2497 | 0ad49876 | Stavros Sachtouris | |
2498 | 0ad49876 | Stavros Sachtouris | * **image-id** is the identifier of the image |
2499 | 0ad49876 | Stavros Sachtouris | * **key** is the key of a matadatum ``key``:``value`` pair |
2500 | 0ad49876 | Stavros Sachtouris | |
2501 | 0ad49876 | Stavros Sachtouris | | |
2502 | 0ad49876 | Stavros Sachtouris | |
2503 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
2504 | 68386e00 | Stavros Sachtouris | Request Header Value Cyclades OS/Compute |
2505 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
2506 | b38e8fa5 | Stavros Sachtouris | X-Auth-Token User authentication token required required |
2507 | b38e8fa5 | Stavros Sachtouris | ============== ========================= ======== ========== |
2508 | c347ba83 | Stavros Sachtouris | |
2509 | 03c9cb80 | Stavros Sachtouris | .. note:: Request parameters should be empty |
2510 | 03c9cb80 | Stavros Sachtouris | |
2511 | 03c9cb80 | Stavros Sachtouris | .. note:: Request body should be empty |
2512 | 03c9cb80 | Stavros Sachtouris | |
2513 | 03c9cb80 | Stavros Sachtouris | .. rubric:: Response |
2514 | e74edfbb | Stavros Sachtouris | |
2515 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2516 | 0ad49876 | Stavros Sachtouris | Return Code Description |
2517 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2518 | 0ad49876 | Stavros Sachtouris | 204 (OK) Request succeeded |
2519 | 0ad49876 | Stavros Sachtouris | 400 (Bad Request) Malformed image ID |
2520 | 0ad49876 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2521 | 0ad49876 | Stavros Sachtouris | 403 (Forbidden) Not allowed to modify this image |
2522 | 0ad49876 | Stavros Sachtouris | 404 (Not Found) Metadatum key not found |
2523 | 0ad49876 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2524 | e7f266c3 | Stavros Sachtouris | \ internal error |
2525 | 0ad49876 | Stavros Sachtouris | 503 (Service Unavailable) The server is not currently available |
2526 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2527 | 2cd1c00a | Giorgos Verigakis | |
2528 | 03c9cb80 | Stavros Sachtouris | .. note:: In case of a 204 code, the response body should be empty. |
2529 | 2cd1c00a | Giorgos Verigakis | |
2530 | 2cd1c00a | Giorgos Verigakis | Networks |
2531 | 2cd1c00a | Giorgos Verigakis | -------- |
2532 | 2cd1c00a | Giorgos Verigakis | |
2533 | 0ad49876 | Stavros Sachtouris | ============= ======== ========== |
2534 | 68386e00 | Stavros Sachtouris | BASE URI Cyclades OS/Compute |
2535 | 0ad49876 | Stavros Sachtouris | ============= ======== ========== |
2536 | 0ad49876 | Stavros Sachtouris | ``/networks`` ✔ **✘** |
2537 | 0ad49876 | Stavros Sachtouris | ============= ======== ========== |
2538 | 2cd1c00a | Giorgos Verigakis | |
2539 | 68386e00 | Stavros Sachtouris | The Network part of Cyclades API is not supported by the OS/Compute API, |
2540 | 7b5eb6ff | Stavros Sachtouris | although it shares some similarities with the |
2541 | 0ad49876 | Stavros Sachtouris | `OS Quantum API <http://docs.openstack.org/api/openstack-network/1.0/content/API_Operations.html>`_. |
2542 | 7b5eb6ff | Stavros Sachtouris | There are key design differences between the two systems but they exceed the |
2543 | 0ad49876 | Stavros Sachtouris | scope of this document, although they affect the respective APIs. |
2544 | 0ad49876 | Stavros Sachtouris | |
2545 | 0ad49876 | Stavros Sachtouris | A Server can connect to one or more networks identified by a numeric id. |
2546 | 0ad49876 | Stavros Sachtouris | Networks are accessible only by the users who created them. When a network is |
2547 | 0ad49876 | Stavros Sachtouris | deleted, all connections to it are deleted. |
2548 | 2cd1c00a | Giorgos Verigakis | |
2549 | c3945370 | Vangelis Koukis | There is a special **public** network with the id *public* that can be accessed |
2550 | c3945370 | Vangelis Koukis | at */networks/public*. All servers are connected to **public** by default and |
2551 | c3945370 | Vangelis Koukis | this network can not be deleted or modified in any way. |
2552 | 2cd1c00a | Giorgos Verigakis | |
2553 | 1730a8b6 | Stavros Sachtouris | =============================================== ================================= ====== |
2554 | 1730a8b6 | Stavros Sachtouris | Description URI Method |
2555 | 1730a8b6 | Stavros Sachtouris | =============================================== ================================= ====== |
2556 | 1730a8b6 | Stavros Sachtouris | `List <#list-networks>`_ ``/networks`` GET |
2557 | 1730a8b6 | Stavros Sachtouris | \ ``/networks/detail`` GET |
2558 | 1730a8b6 | Stavros Sachtouris | `Create <#create-network>`_ ``/networks`` POST |
2559 | 1730a8b6 | Stavros Sachtouris | `Get details <#get-network-details>`_ ``/networks/<network-id>`` GET |
2560 | 1730a8b6 | Stavros Sachtouris | `Rename <#rename-network>`_ ``/networks/<network-id>`` PUT |
2561 | 1730a8b6 | Stavros Sachtouris | `Delete <#delete-network>`_ ``/networks/<network-id>`` DELETE |
2562 | 1730a8b6 | Stavros Sachtouris | `Connect <#connect-network-to-server>`_ ``/networks/<network-id>/action`` POST |
2563 | 1730a8b6 | Stavros Sachtouris | `Disconnect <#disconnect-network-from-server>`_ ``/networks/<network-id>/action`` POST |
2564 | 1730a8b6 | Stavros Sachtouris | =============================================== ================================= ====== |
2565 | 1730a8b6 | Stavros Sachtouris | |
2566 | 1730a8b6 | Stavros Sachtouris | |
2567 | 2cd1c00a | Giorgos Verigakis | List Networks |
2568 | 2cd1c00a | Giorgos Verigakis | ............. |
2569 | 2cd1c00a | Giorgos Verigakis | |
2570 | 0ad49876 | Stavros Sachtouris | This operation lists the networks associated with a users account |
2571 | 2cd1c00a | Giorgos Verigakis | |
2572 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2573 | 7b5eb6ff | Stavros Sachtouris | |
2574 | 0ad49876 | Stavros Sachtouris | ==================== ====== |
2575 | 0ad49876 | Stavros Sachtouris | URI Method |
2576 | 0ad49876 | Stavros Sachtouris | ==================== ====== |
2577 | 0ad49876 | Stavros Sachtouris | ``/networks`` GET |
2578 | 0ad49876 | Stavros Sachtouris | ``/networks/detail`` GET |
2579 | 0ad49876 | Stavros Sachtouris | ==================== ====== |
2580 | 2cd1c00a | Giorgos Verigakis | |
2581 | 0ad49876 | Stavros Sachtouris | | |
2582 | 2cd1c00a | Giorgos Verigakis | |
2583 | 0ad49876 | Stavros Sachtouris | ============== ========================= |
2584 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2585 | 0ad49876 | Stavros Sachtouris | ============== ========================= |
2586 | 0ad49876 | Stavros Sachtouris | X-Auth-Token User authentication token |
2587 | 0ad49876 | Stavros Sachtouris | ============== ========================= |
2588 | 2cd1c00a | Giorgos Verigakis | |
2589 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2590 | 7b5eb6ff | Stavros Sachtouris | |
2591 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request body should be empty |
2592 | 7b5eb6ff | Stavros Sachtouris | |
2593 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
2594 | 2cd1c00a | Giorgos Verigakis | |
2595 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2596 | 0ad49876 | Stavros Sachtouris | Return Code Description |
2597 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2598 | 0ad49876 | Stavros Sachtouris | 204 (OK) Request succeeded |
2599 | 3458183d | Constantinos Venetsanopoulos | 304 (Not Modified) |
2600 | 0ad49876 | Stavros Sachtouris | 400 (Bad Request) Malformed network id |
2601 | 0ad49876 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2602 | 0ad49876 | Stavros Sachtouris | 404 (Not Found) Network not found |
2603 | 0ad49876 | Stavros Sachtouris | 409 (Build In Progress) Server is not ready yet |
2604 | 0ad49876 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2605 | e7f266c3 | Stavros Sachtouris | \ internal error |
2606 | 0ad49876 | Stavros Sachtouris | 503 (Service Unavailable) Action not supported or service currently |
2607 | e7f266c3 | Stavros Sachtouris | \ unavailable |
2608 | 0ad49876 | Stavros Sachtouris | =========================== ===================== |
2609 | 0ad49876 | Stavros Sachtouris | |
2610 | 7b5eb6ff | Stavros Sachtouris | Response body content:: |
2611 | 7b5eb6ff | Stavros Sachtouris | |
2612 | 7b5eb6ff | Stavros Sachtouris | networks: { |
2613 | 7b5eb6ff | Stavros Sachtouris | values: [ |
2614 | 7b5eb6ff | Stavros Sachtouris | { |
2615 | 7b5eb6ff | Stavros Sachtouris | <network attribute>: <value>, |
2616 | 7b5eb6ff | Stavros Sachtouris | ... |
2617 | 7b5eb6ff | Stavros Sachtouris | }, |
2618 | 7b5eb6ff | Stavros Sachtouris | ... |
2619 | 7b5eb6ff | Stavros Sachtouris | ] |
2620 | 7b5eb6ff | Stavros Sachtouris | } |
2621 | 7b5eb6ff | Stavros Sachtouris | |
2622 | 0ad49876 | Stavros Sachtouris | The ``detail`` operation lists the `full network attributes <#network-ref>`_, |
2623 | 7b5eb6ff | Stavros Sachtouris | while the regular operation returns only the ``id`` and ``name`` attributes. |
2624 | 0ad49876 | Stavros Sachtouris | |
2625 | 634ef3a8 | Stavros Sachtouris | *Example Networks List Response: JSON (regular)* |
2626 | 0ad49876 | Stavros Sachtouris | |
2627 | 0ad49876 | Stavros Sachtouris | .. code-block:: javascript |
2628 | 0ad49876 | Stavros Sachtouris | |
2629 | 0ad49876 | Stavros Sachtouris | { |
2630 | 0ad49876 | Stavros Sachtouris | "networks": { |
2631 | 0ad49876 | Stavros Sachtouris | "values": [ |
2632 | 7b5eb6ff | Stavros Sachtouris | {"id": "1", "name": "public"}, |
2633 | 7b5eb6ff | Stavros Sachtouris | {"id": "2", "name": "my private network"} |
2634 | 0ad49876 | Stavros Sachtouris | ] |
2635 | 0ad49876 | Stavros Sachtouris | } |
2636 | 0ad49876 | Stavros Sachtouris | } |
2637 | 2cd1c00a | Giorgos Verigakis | |
2638 | 634ef3a8 | Stavros Sachtouris | *Example Networks List Response: JSON (detail)* |
2639 | c3945370 | Vangelis Koukis | |
2640 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
2641 | 2cd1c00a | Giorgos Verigakis | |
2642 | 2cd1c00a | Giorgos Verigakis | { |
2643 | f76ec11f | Stavros Sachtouris | "networks": { |
2644 | f76ec11f | Stavros Sachtouris | "values": [ |
2645 | f76ec11f | Stavros Sachtouris | { |
2646 | 0ad49876 | Stavros Sachtouris | "id": "1", |
2647 | f76ec11f | Stavros Sachtouris | "name": "public", |
2648 | f76ec11f | Stavros Sachtouris | "created": "2011-04-20T15:31:08.199640+00:00", |
2649 | f76ec11f | Stavros Sachtouris | "updated": "2011-05-06T12:47:05.582679+00:00", |
2650 | 0ad49876 | Stavros Sachtouris | "attachments": {"values": ["nic-42-0", "nic-73-0"]} |
2651 | f76ec11f | Stavros Sachtouris | }, { |
2652 | f76ec11f | Stavros Sachtouris | "id": 2, |
2653 | 0ad49876 | Stavros Sachtouris | "name": "my private network", |
2654 | f76ec11f | Stavros Sachtouris | "created": "2011-04-20T14:32:08.199640+00:00", |
2655 | f76ec11f | Stavros Sachtouris | "updated": "2011-05-06T11:40:05.582679+00:00", |
2656 | 0ad49876 | Stavros Sachtouris | "attachments": {"values": ["nic-42-2", "nic-7-3"]} |
2657 | f76ec11f | Stavros Sachtouris | } |
2658 | f76ec11f | Stavros Sachtouris | ] |
2659 | f76ec11f | Stavros Sachtouris | } |
2660 | 2cd1c00a | Giorgos Verigakis | } |
2661 | 2cd1c00a | Giorgos Verigakis | |
2662 | 2cd1c00a | Giorgos Verigakis | |
2663 | 2cd1c00a | Giorgos Verigakis | Create Network |
2664 | 2cd1c00a | Giorgos Verigakis | .............. |
2665 | 2cd1c00a | Giorgos Verigakis | |
2666 | 7b5eb6ff | Stavros Sachtouris | This operation asynchronously provisions a new network. |
2667 | 7b5eb6ff | Stavros Sachtouris | |
2668 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2669 | 2cd1c00a | Giorgos Verigakis | |
2670 | 008c941f | Stavros Sachtouris | ==================== ====== |
2671 | 008c941f | Stavros Sachtouris | URI Method |
2672 | 008c941f | Stavros Sachtouris | ==================== ====== |
2673 | 008c941f | Stavros Sachtouris | ``/networks`` POST |
2674 | 008c941f | Stavros Sachtouris | ==================== ====== |
2675 | 2cd1c00a | Giorgos Verigakis | |
2676 | 008c941f | Stavros Sachtouris | | |
2677 | 008c941f | Stavros Sachtouris | |
2678 | 008c941f | Stavros Sachtouris | ============== ========================= |
2679 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2680 | 008c941f | Stavros Sachtouris | ============== ========================= |
2681 | 008c941f | Stavros Sachtouris | X-Auth-Token User authentication token |
2682 | 634ef3a8 | Stavros Sachtouris | Content-Type Type or request body |
2683 | 634ef3a8 | Stavros Sachtouris | Content-Length Length of request body |
2684 | 008c941f | Stavros Sachtouris | ============== ========================= |
2685 | 008c941f | Stavros Sachtouris | |
2686 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
2687 | 634ef3a8 | Stavros Sachtouris | |
2688 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
2689 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
2690 | 634ef3a8 | Stavros Sachtouris | Content-Length: 60 |
2691 | 634ef3a8 | Stavros Sachtouris | |
2692 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2693 | 008c941f | Stavros Sachtouris | |
2694 | 7b5eb6ff | Stavros Sachtouris | Request body content:: |
2695 | 7b5eb6ff | Stavros Sachtouris | |
2696 | 7b5eb6ff | Stavros Sachtouris | network: { |
2697 | 7b5eb6ff | Stavros Sachtouris | <request attribute>: <value>, |
2698 | 7b5eb6ff | Stavros Sachtouris | ... |
2699 | 7b5eb6ff | Stavros Sachtouris | } |
2700 | 008c941f | Stavros Sachtouris | |
2701 | 008c941f | Stavros Sachtouris | ================== ======================= ======== ======= |
2702 | 008c941f | Stavros Sachtouris | Request Attributes Description Required Default |
2703 | 008c941f | Stavros Sachtouris | ================== ======================= ======== ======= |
2704 | 3458183d | Constantinos Venetsanopoulos | name Network name ✔ |
2705 | 008c941f | Stavros Sachtouris | type Network type ✔ |
2706 | 008c941f | Stavros Sachtouris | dhcp If use DHCP **✘** True |
2707 | 008c941f | Stavros Sachtouris | cidr IPv4 CIDR **✘** 192.168.1.0/2 |
2708 | 008c941f | Stavros Sachtouris | cidr6 IPv6 CDIR **✘** null |
2709 | 008c941f | Stavros Sachtouris | gateway IPv4 gateway address **✘** null |
2710 | 008c941f | Stavros Sachtouris | gateway6 IPv6 gateway address **✘** null |
2711 | 008c941f | Stavros Sachtouris | public If a public network **✘** False |
2712 | 008c941f | Stavros Sachtouris | ================== ======================= ======== ======= |
2713 | 008c941f | Stavros Sachtouris | |
2714 | 008c941f | Stavros Sachtouris | * **name** is a string |
2715 | 008c941f | Stavros Sachtouris | |
2716 | 008c941f | Stavros Sachtouris | * **type** can be CUSTOM, IP_LESS_ROUTED, MAC_FILTERED, PHYSICAL_VLAN |
2717 | 008c941f | Stavros Sachtouris | |
2718 | 008c941f | Stavros Sachtouris | * **dhcp** and **public** are flags |
2719 | 2cd1c00a | Giorgos Verigakis | |
2720 | 008c941f | Stavros Sachtouris | * **cidr**, and **gateway** are IPv4 addresses |
2721 | 2cd1c00a | Giorgos Verigakis | |
2722 | 008c941f | Stavros Sachtouris | * **cidr6**, and **gateway6** are IPv6 addresses |
2723 | 008c941f | Stavros Sachtouris | |
2724 | b38e8fa5 | Stavros Sachtouris | * **public** should better not be used. If True, a 403 error is returned. |
2725 | 008c941f | Stavros Sachtouris | |
2726 | 634ef3a8 | Stavros Sachtouris | *Example Create Network Request Body: JSON* |
2727 | c3945370 | Vangelis Koukis | |
2728 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
2729 | 2cd1c00a | Giorgos Verigakis | |
2730 | b38e8fa5 | Stavros Sachtouris | {"network": {"name": "private_net", "type": "MAC_FILTERED"}} |
2731 | 2cd1c00a | Giorgos Verigakis | |
2732 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
2733 | 008c941f | Stavros Sachtouris | |
2734 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2735 | 008c941f | Stavros Sachtouris | Return Code Description |
2736 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2737 | 008c941f | Stavros Sachtouris | 202 (OK) Request succeeded |
2738 | 008c941f | Stavros Sachtouris | 400 (Bad Request) Malformed network id or request |
2739 | 008c941f | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2740 | 008c941f | Stavros Sachtouris | 403 (Forbidden) Public network is forbidden |
2741 | 008c941f | Stavros Sachtouris | 404 (Not Found) Network not found |
2742 | 008c941f | Stavros Sachtouris | 413 (Over Limit) Reached networks limit |
2743 | 008c941f | Stavros Sachtouris | 415 (Bad Media Type) Bad network type |
2744 | 008c941f | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2745 | e7f266c3 | Stavros Sachtouris | \ internal error |
2746 | 008c941f | Stavros Sachtouris | 503 (Service Unavailable) Failed to allocated network resources |
2747 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2748 | 008c941f | Stavros Sachtouris | |
2749 | 7b5eb6ff | Stavros Sachtouris | Response body content:: |
2750 | 7b5eb6ff | Stavros Sachtouris | |
2751 | 7b5eb6ff | Stavros Sachtouris | network: { |
2752 | 7b5eb6ff | Stavros Sachtouris | <network attribute>: <value>, |
2753 | 7b5eb6ff | Stavros Sachtouris | ... |
2754 | 7b5eb6ff | Stavros Sachtouris | } |
2755 | 7b5eb6ff | Stavros Sachtouris | |
2756 | 7b5eb6ff | Stavros Sachtouris | A list of the valid network attributes can be found `here <#network-ref>`_. |
2757 | 008c941f | Stavros Sachtouris | |
2758 | 634ef3a8 | Stavros Sachtouris | *Example Create Network Response: JSON* |
2759 | c3945370 | Vangelis Koukis | |
2760 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
2761 | 2cd1c00a | Giorgos Verigakis | |
2762 | 2cd1c00a | Giorgos Verigakis | { |
2763 | 008c941f | Stavros Sachtouris | "network": { |
2764 | 008c941f | Stavros Sachtouris | "status": "PENDING", |
2765 | 008c941f | Stavros Sachtouris | "updated": "2013-04-25T13:31:17.165237+00:00", |
2766 | 008c941f | Stavros Sachtouris | "name": "my private network", |
2767 | 008c941f | Stavros Sachtouris | "created": "2013-04-25T13:31:17.165088+00:00", |
2768 | 008c941f | Stavros Sachtouris | "cidr6": null, |
2769 | 008c941f | Stavros Sachtouris | "id": "6567", |
2770 | 008c941f | Stavros Sachtouris | "gateway6": null, |
2771 | 008c941f | Stavros Sachtouris | "public": false, |
2772 | 008c941f | Stavros Sachtouris | "dhcp": false, |
2773 | 008c941f | Stavros Sachtouris | "cidr": "192.168.1.0/24", |
2774 | 008c941f | Stavros Sachtouris | "type": "MAC_FILTERED", |
2775 | 008c941f | Stavros Sachtouris | "gateway": null, |
2776 | 008c941f | Stavros Sachtouris | "attachments": {"values": []} |
2777 | 008c941f | Stavros Sachtouris | } |
2778 | 2cd1c00a | Giorgos Verigakis | } |
2779 | 2cd1c00a | Giorgos Verigakis | |
2780 | 008c941f | Stavros Sachtouris | Get Network Details |
2781 | 008c941f | Stavros Sachtouris | ................... |
2782 | 2cd1c00a | Giorgos Verigakis | |
2783 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2784 | 7b5eb6ff | Stavros Sachtouris | |
2785 | 008c941f | Stavros Sachtouris | ========================== ====== |
2786 | 008c941f | Stavros Sachtouris | URI Method |
2787 | 008c941f | Stavros Sachtouris | ========================== ====== |
2788 | 3458183d | Constantinos Venetsanopoulos | ``/networks/<network-id>`` GET |
2789 | 008c941f | Stavros Sachtouris | ========================== ====== |
2790 | 2cd1c00a | Giorgos Verigakis | |
2791 | 008c941f | Stavros Sachtouris | * **network-id** is the identifier of the network |
2792 | 2cd1c00a | Giorgos Verigakis | |
2793 | 008c941f | Stavros Sachtouris | | |
2794 | 2cd1c00a | Giorgos Verigakis | |
2795 | 008c941f | Stavros Sachtouris | ============== ========================= |
2796 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2797 | 008c941f | Stavros Sachtouris | ============== ========================= |
2798 | 008c941f | Stavros Sachtouris | X-Auth-Token User authentication token |
2799 | 008c941f | Stavros Sachtouris | ============== ========================= |
2800 | 2cd1c00a | Giorgos Verigakis | |
2801 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2802 | 7b5eb6ff | Stavros Sachtouris | |
2803 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request body should be empty |
2804 | 7b5eb6ff | Stavros Sachtouris | |
2805 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
2806 | 2cd1c00a | Giorgos Verigakis | |
2807 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2808 | 008c941f | Stavros Sachtouris | Return Code Description |
2809 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2810 | 008c941f | Stavros Sachtouris | 200 (OK) Request succeeded |
2811 | 008c941f | Stavros Sachtouris | 400 (Bad Request) Malformed request or network id |
2812 | 008c941f | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2813 | 008c941f | Stavros Sachtouris | 404 (Not Found) Network not found |
2814 | 008c941f | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2815 | e7f266c3 | Stavros Sachtouris | \ internal error |
2816 | 008c941f | Stavros Sachtouris | 503 (Service Unavailable) The service is not currently available |
2817 | 008c941f | Stavros Sachtouris | =========================== ===================== |
2818 | 2cd1c00a | Giorgos Verigakis | |
2819 | 7b5eb6ff | Stavros Sachtouris | Response code content:: |
2820 | 2cd1c00a | Giorgos Verigakis | |
2821 | 7b5eb6ff | Stavros Sachtouris | network: { |
2822 | 7b5eb6ff | Stavros Sachtouris | <network attribute>: <value>, |
2823 | 7b5eb6ff | Stavros Sachtouris | ... |
2824 | 7b5eb6ff | Stavros Sachtouris | } |
2825 | 7b5eb6ff | Stavros Sachtouris | |
2826 | 7b5eb6ff | Stavros Sachtouris | A list of network attributes can be found `here <#network-ref>`_. |
2827 | 2cd1c00a | Giorgos Verigakis | |
2828 | 634ef3a8 | Stavros Sachtouris | *Example Get Network Details Response: JSON* |
2829 | c3945370 | Vangelis Koukis | |
2830 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
2831 | 2cd1c00a | Giorgos Verigakis | |
2832 | 2cd1c00a | Giorgos Verigakis | { |
2833 | 008c941f | Stavros Sachtouris | "network": { |
2834 | 008c941f | Stavros Sachtouris | "status": "PENDING", |
2835 | 008c941f | Stavros Sachtouris | "updated": "2013-04-25T13:31:17.165237+00:00", |
2836 | 008c941f | Stavros Sachtouris | "name": "my private network", |
2837 | 008c941f | Stavros Sachtouris | "created": "2013-04-25T13:31:17.165088+00:00", |
2838 | 008c941f | Stavros Sachtouris | "cidr6": null, |
2839 | 008c941f | Stavros Sachtouris | "id": "6567", |
2840 | 008c941f | Stavros Sachtouris | "gateway6": null, |
2841 | 008c941f | Stavros Sachtouris | "public": false, |
2842 | 008c941f | Stavros Sachtouris | "dhcp": false, |
2843 | 008c941f | Stavros Sachtouris | "cidr": "192.168.1.0/24", |
2844 | 008c941f | Stavros Sachtouris | "type": "MAC_FILTERED", |
2845 | 008c941f | Stavros Sachtouris | "gateway": null, |
2846 | 008c941f | Stavros Sachtouris | "attachments": {"values": []} |
2847 | 008c941f | Stavros Sachtouris | } |
2848 | 2cd1c00a | Giorgos Verigakis | } |
2849 | 2cd1c00a | Giorgos Verigakis | |
2850 | be0c2495 | Stavros Sachtouris | Rename Network |
2851 | be0c2495 | Stavros Sachtouris | .............. |
2852 | 2cd1c00a | Giorgos Verigakis | |
2853 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2854 | 7b5eb6ff | Stavros Sachtouris | |
2855 | be0c2495 | Stavros Sachtouris | ========================== ====== |
2856 | be0c2495 | Stavros Sachtouris | URI Method |
2857 | be0c2495 | Stavros Sachtouris | ========================== ====== |
2858 | 3458183d | Constantinos Venetsanopoulos | ``/networks/<network-id>`` PUT |
2859 | be0c2495 | Stavros Sachtouris | ========================== ====== |
2860 | 2cd1c00a | Giorgos Verigakis | |
2861 | be0c2495 | Stavros Sachtouris | * **network-id** is the identifier of the network |
2862 | be0c2495 | Stavros Sachtouris | |
2863 | be0c2495 | Stavros Sachtouris | | |
2864 | be0c2495 | Stavros Sachtouris | |
2865 | be0c2495 | Stavros Sachtouris | ============== ========================= |
2866 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2867 | be0c2495 | Stavros Sachtouris | ============== ========================= |
2868 | be0c2495 | Stavros Sachtouris | X-Auth-Token User authentication token |
2869 | 3458183d | Constantinos Venetsanopoulos | Content-Type Type or request body |
2870 | 3458183d | Constantinos Venetsanopoulos | Content-Length Length of request body |
2871 | be0c2495 | Stavros Sachtouris | ============== ========================= |
2872 | be0c2495 | Stavros Sachtouris | |
2873 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
2874 | 634ef3a8 | Stavros Sachtouris | |
2875 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
2876 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
2877 | 634ef3a8 | Stavros Sachtouris | Content-Length: 33 |
2878 | 634ef3a8 | Stavros Sachtouris | |
2879 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2880 | be0c2495 | Stavros Sachtouris | |
2881 | 7b5eb6ff | Stavros Sachtouris | Request body content:: |
2882 | 2cd1c00a | Giorgos Verigakis | |
2883 | 7b5eb6ff | Stavros Sachtouris | network: {name: <new value>} |
2884 | 2cd1c00a | Giorgos Verigakis | |
2885 | 634ef3a8 | Stavros Sachtouris | *Example Update Network Name Request: JSON* |
2886 | 2cd1c00a | Giorgos Verigakis | |
2887 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
2888 | c3945370 | Vangelis Koukis | |
2889 | be0c2495 | Stavros Sachtouris | {"network": {"name": "new_name"}} |
2890 | 2cd1c00a | Giorgos Verigakis | |
2891 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
2892 | be0c2495 | Stavros Sachtouris | |
2893 | be0c2495 | Stavros Sachtouris | =========================== ===================== |
2894 | be0c2495 | Stavros Sachtouris | Return Code Description |
2895 | be0c2495 | Stavros Sachtouris | =========================== ===================== |
2896 | be0c2495 | Stavros Sachtouris | 204 (OK) Request succeeded |
2897 | be0c2495 | Stavros Sachtouris | 400 (Bad Request) Malformed request or network deleted |
2898 | be0c2495 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2899 | be0c2495 | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
2900 | e7f266c3 | Stavros Sachtouris | 404 (Not Found) Network not found |
2901 | be0c2495 | Stavros Sachtouris | 413 (Over Limit) Network Limit Exceeded |
2902 | be0c2495 | Stavros Sachtouris | 415 (Bad Media Type) Bad network type |
2903 | be0c2495 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2904 | e7f266c3 | Stavros Sachtouris | \ internal error |
2905 | be0c2495 | Stavros Sachtouris | 503 (Service Unavailable) The service is not currently available |
2906 | be0c2495 | Stavros Sachtouris | =========================== ===================== |
2907 | 2cd1c00a | Giorgos Verigakis | |
2908 | 7b5eb6ff | Stavros Sachtouris | .. note:: In case of a 204 code, the response body should be empty |
2909 | 2cd1c00a | Giorgos Verigakis | |
2910 | 2cd1c00a | Giorgos Verigakis | Delete Network |
2911 | 2cd1c00a | Giorgos Verigakis | .............. |
2912 | 2cd1c00a | Giorgos Verigakis | |
2913 | 7b5eb6ff | Stavros Sachtouris | A network is deleted as long as it is not attached to any virtual servers. |
2914 | 7b5eb6ff | Stavros Sachtouris | |
2915 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2916 | 7b5eb6ff | Stavros Sachtouris | |
2917 | e7f266c3 | Stavros Sachtouris | ========================== ====== |
2918 | e7f266c3 | Stavros Sachtouris | URI Method |
2919 | e7f266c3 | Stavros Sachtouris | ========================== ====== |
2920 | 3458183d | Constantinos Venetsanopoulos | ``/networks/<network-id>`` DELETE |
2921 | e7f266c3 | Stavros Sachtouris | ========================== ====== |
2922 | 2cd1c00a | Giorgos Verigakis | |
2923 | e7f266c3 | Stavros Sachtouris | * **network-id** is the identifier of the network |
2924 | 2cd1c00a | Giorgos Verigakis | |
2925 | e7f266c3 | Stavros Sachtouris | | |
2926 | 2cd1c00a | Giorgos Verigakis | |
2927 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2928 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2929 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2930 | e7f266c3 | Stavros Sachtouris | X-Auth-Token User authentication token |
2931 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2932 | 2cd1c00a | Giorgos Verigakis | |
2933 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2934 | 7b5eb6ff | Stavros Sachtouris | |
2935 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request body should be empty |
2936 | 7b5eb6ff | Stavros Sachtouris | |
2937 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
2938 | 2cd1c00a | Giorgos Verigakis | |
2939 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
2940 | e7f266c3 | Stavros Sachtouris | Return Code Description |
2941 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
2942 | e7f266c3 | Stavros Sachtouris | 204 (OK) Request succeeded |
2943 | e7f266c3 | Stavros Sachtouris | 400 (Bad Request) Malformed request or network already deleted |
2944 | e7f266c3 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
2945 | e7f266c3 | Stavros Sachtouris | 403 (Forbidden) Administratively suspended server |
2946 | e7f266c3 | Stavros Sachtouris | 404 (Not Found) Network not found |
2947 | 7b5eb6ff | Stavros Sachtouris | 421 (Network In Use) The network is in use and cannot be deleted |
2948 | e7f266c3 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
2949 | e7f266c3 | Stavros Sachtouris | \ internal error |
2950 | e7f266c3 | Stavros Sachtouris | 503 (Service Unavailable) The service is not currently available |
2951 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
2952 | 2cd1c00a | Giorgos Verigakis | |
2953 | 7b5eb6ff | Stavros Sachtouris | .. note:: In case of a 204 code, the response body should be empty |
2954 | 7b5eb6ff | Stavros Sachtouris | |
2955 | 7b5eb6ff | Stavros Sachtouris | |
2956 | 7b5eb6ff | Stavros Sachtouris | Connect network to Server |
2957 | 7b5eb6ff | Stavros Sachtouris | .......................... |
2958 | 7b5eb6ff | Stavros Sachtouris | |
2959 | 7b5eb6ff | Stavros Sachtouris | Connect a network to a virtual server. The effect of this operation is the |
2960 | 7b5eb6ff | Stavros Sachtouris | creation of a NIC that connects the two parts. |
2961 | 7b5eb6ff | Stavros Sachtouris | |
2962 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
2963 | 2cd1c00a | Giorgos Verigakis | |
2964 | e7f266c3 | Stavros Sachtouris | ================================= ====== |
2965 | e7f266c3 | Stavros Sachtouris | URI Method |
2966 | e7f266c3 | Stavros Sachtouris | ================================= ====== |
2967 | e7f266c3 | Stavros Sachtouris | ``/networks/<network-id>/action`` POST |
2968 | e7f266c3 | Stavros Sachtouris | ================================= ====== |
2969 | c3945370 | Vangelis Koukis | |
2970 | e7f266c3 | Stavros Sachtouris | * **network-id** is the identifier of the network |
2971 | 2cd1c00a | Giorgos Verigakis | |
2972 | 634ef3a8 | Stavros Sachtouris | | |
2973 | 634ef3a8 | Stavros Sachtouris | |
2974 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2975 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
2976 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2977 | e7f266c3 | Stavros Sachtouris | X-Auth-Token User authentication token |
2978 | 3458183d | Constantinos Venetsanopoulos | Content-Type Type or request body |
2979 | 3458183d | Constantinos Venetsanopoulos | Content-Length Length of request body |
2980 | e7f266c3 | Stavros Sachtouris | ============== ========================= |
2981 | 2cd1c00a | Giorgos Verigakis | |
2982 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
2983 | 634ef3a8 | Stavros Sachtouris | |
2984 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
2985 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
2986 | 634ef3a8 | Stavros Sachtouris | Content-Length: 28 |
2987 | 634ef3a8 | Stavros Sachtouris | |
2988 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
2989 | 2cd1c00a | Giorgos Verigakis | |
2990 | 7b5eb6ff | Stavros Sachtouris | Response body content (connect):: |
2991 | 2cd1c00a | Giorgos Verigakis | |
2992 | 7b5eb6ff | Stavros Sachtouris | add {serverRef: <server id to connect>} |
2993 | 2cd1c00a | Giorgos Verigakis | |
2994 | 634ef3a8 | Stavros Sachtouris | *Example Action Add (connect to): JSON* |
2995 | 2cd1c00a | Giorgos Verigakis | |
2996 | e7f266c3 | Stavros Sachtouris | .. code-block:: javascript |
2997 | 2cd1c00a | Giorgos Verigakis | |
2998 | e7f266c3 | Stavros Sachtouris | {"add" : {"serverRef" : 42}} |
2999 | 2cd1c00a | Giorgos Verigakis | |
3000 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
3001 | 7b5eb6ff | Stavros Sachtouris | |
3002 | 7b5eb6ff | Stavros Sachtouris | =========================== ===================== |
3003 | 7b5eb6ff | Stavros Sachtouris | Return Code Description |
3004 | 7b5eb6ff | Stavros Sachtouris | =========================== ===================== |
3005 | 7b5eb6ff | Stavros Sachtouris | 202 (OK) Request succeeded |
3006 | 7b5eb6ff | Stavros Sachtouris | 400 (Bad Request) Malformed request or network already deleted |
3007 | 7b5eb6ff | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
3008 | 7b5eb6ff | Stavros Sachtouris | 403 (Forbidden) Not allowed to modify this network (e.g. public) |
3009 | 7b5eb6ff | Stavros Sachtouris | 404 (Not Found) Network not found |
3010 | 7b5eb6ff | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
3011 | 7b5eb6ff | Stavros Sachtouris | \ internal error |
3012 | 7b5eb6ff | Stavros Sachtouris | 503 (Service Unavailable) The service is not currently available |
3013 | 7b5eb6ff | Stavros Sachtouris | =========================== ===================== |
3014 | 7b5eb6ff | Stavros Sachtouris | |
3015 | 7b5eb6ff | Stavros Sachtouris | .. note:: In case of a 202 code, the request body should be empty |
3016 | 7b5eb6ff | Stavros Sachtouris | |
3017 | 7b5eb6ff | Stavros Sachtouris | Disconnect network from Server |
3018 | 7b5eb6ff | Stavros Sachtouris | .............................. |
3019 | 7b5eb6ff | Stavros Sachtouris | |
3020 | 7b5eb6ff | Stavros Sachtouris | Disconnect a network from a virtual server. The effect of this operation is the |
3021 | 7b5eb6ff | Stavros Sachtouris | deletion of the NIC that connects the two parts. |
3022 | 7b5eb6ff | Stavros Sachtouris | |
3023 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Request |
3024 | 7b5eb6ff | Stavros Sachtouris | |
3025 | 7b5eb6ff | Stavros Sachtouris | ================================= ====== |
3026 | 7b5eb6ff | Stavros Sachtouris | URI Method |
3027 | 7b5eb6ff | Stavros Sachtouris | ================================= ====== |
3028 | 7b5eb6ff | Stavros Sachtouris | ``/networks/<network-id>/action`` POST |
3029 | 7b5eb6ff | Stavros Sachtouris | ================================= ====== |
3030 | 7b5eb6ff | Stavros Sachtouris | |
3031 | 7b5eb6ff | Stavros Sachtouris | * **network-id** is the identifier of the network |
3032 | 7b5eb6ff | Stavros Sachtouris | |
3033 | 634ef3a8 | Stavros Sachtouris | | |
3034 | 634ef3a8 | Stavros Sachtouris | |
3035 | 7b5eb6ff | Stavros Sachtouris | ============== ========================= |
3036 | 3458183d | Constantinos Venetsanopoulos | Request Header Value |
3037 | 7b5eb6ff | Stavros Sachtouris | ============== ========================= |
3038 | 7b5eb6ff | Stavros Sachtouris | X-Auth-Token User authentication token |
3039 | 3458183d | Constantinos Venetsanopoulos | Content-Type Type or request body |
3040 | 3458183d | Constantinos Venetsanopoulos | Content-Length Length of request body |
3041 | 7b5eb6ff | Stavros Sachtouris | ============== ========================= |
3042 | 7b5eb6ff | Stavros Sachtouris | |
3043 | 634ef3a8 | Stavros Sachtouris | **Example Request Headers**:: |
3044 | 634ef3a8 | Stavros Sachtouris | |
3045 | 634ef3a8 | Stavros Sachtouris | X-Auth-Token: z31uRXUn1LZy45p1r7V== |
3046 | 634ef3a8 | Stavros Sachtouris | Content-Type: application/json |
3047 | 634ef3a8 | Stavros Sachtouris | Content-Length: 31 |
3048 | 634ef3a8 | Stavros Sachtouris | |
3049 | 7b5eb6ff | Stavros Sachtouris | .. note:: Request parameters should be empty |
3050 | 7b5eb6ff | Stavros Sachtouris | |
3051 | 7b5eb6ff | Stavros Sachtouris | Response body content (disconnect):: |
3052 | 7b5eb6ff | Stavros Sachtouris | |
3053 | 7b5eb6ff | Stavros Sachtouris | remove {serverRef: <server id to disconnect>} |
3054 | 7b5eb6ff | Stavros Sachtouris | |
3055 | 634ef3a8 | Stavros Sachtouris | *Example Action Remove (disconnect from): JSON* |
3056 | c3945370 | Vangelis Koukis | |
3057 | c3945370 | Vangelis Koukis | .. code-block:: javascript |
3058 | 2cd1c00a | Giorgos Verigakis | |
3059 | e7f266c3 | Stavros Sachtouris | {"remove" : {"serverRef" : 42}} |
3060 | 2cd1c00a | Giorgos Verigakis | |
3061 | 7b5eb6ff | Stavros Sachtouris | .. rubric:: Response |
3062 | 0e214bbe | Stavros Sachtouris | |
3063 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
3064 | e7f266c3 | Stavros Sachtouris | Return Code Description |
3065 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
3066 | 7b5eb6ff | Stavros Sachtouris | 202 (OK) Request succeeded |
3067 | e7f266c3 | Stavros Sachtouris | 400 (Bad Request) Malformed request or network already deleted |
3068 | e7f266c3 | Stavros Sachtouris | 401 (Unauthorized) Missing or expired user token |
3069 | e7f266c3 | Stavros Sachtouris | 403 (Forbidden) Not allowed to modify this network (e.g. public) |
3070 | e7f266c3 | Stavros Sachtouris | 404 (Not Found) Network not found |
3071 | e7f266c3 | Stavros Sachtouris | 500 (Internal Server Error) The request cannot be completed because of an |
3072 | e7f266c3 | Stavros Sachtouris | \ internal error |
3073 | e7f266c3 | Stavros Sachtouris | 503 (Service Unavailable) The service is not currently available |
3074 | e7f266c3 | Stavros Sachtouris | =========================== ===================== |
3075 | e7f266c3 | Stavros Sachtouris | |
3076 | 7b5eb6ff | Stavros Sachtouris | .. note:: In case of a 202 code, the request body should be empty |
3077 | e7f266c3 | Stavros Sachtouris | |
3078 | e7f266c3 | Stavros Sachtouris | Index of Attributes |
3079 | e7f266c3 | Stavros Sachtouris | ------------------- |
3080 | 0e214bbe | Stavros Sachtouris | |
3081 | 0e214bbe | Stavros Sachtouris | .. _server-ref: |
3082 | 0e214bbe | Stavros Sachtouris | |
3083 | 0e214bbe | Stavros Sachtouris | Server Attributes |
3084 | 0e214bbe | Stavros Sachtouris | ................. |
3085 | 0e214bbe | Stavros Sachtouris | |
3086 | 0e214bbe | Stavros Sachtouris | ================ ========================== ======== ========== |
3087 | 68386e00 | Stavros Sachtouris | Server attribute Description Cyclades OS/Compute |
3088 | 0e214bbe | Stavros Sachtouris | ================ ========================== ======== ========== |
3089 | 0e214bbe | Stavros Sachtouris | id Server ID ✔ ✔ |
3090 | 0e214bbe | Stavros Sachtouris | name Server Name ✔ ✔ |
3091 | 0e214bbe | Stavros Sachtouris | status Server Status ✔ ✔ |
3092 | 0e214bbe | Stavros Sachtouris | updated Date of last modification ✔ ✔ |
3093 | 0e214bbe | Stavros Sachtouris | created Date of creation ✔ ✔ |
3094 | 0e214bbe | Stavros Sachtouris | hostId Physical host empty ✔ |
3095 | 0e214bbe | Stavros Sachtouris | imageRef Image ID ✔ **✘** |
3096 | 0e214bbe | Stavros Sachtouris | image A full image descreption **✘** ✔ |
3097 | 0e214bbe | Stavros Sachtouris | flavorRef Flavor ID ✔ **✘** |
3098 | 0e214bbe | Stavros Sachtouris | flavor A full flavor description **✘** ✔ |
3099 | 0e214bbe | Stavros Sachtouris | adminPass Superuser Password ✔ ✔ |
3100 | 0e214bbe | Stavros Sachtouris | suspended If server is suspended ✔ ✔ |
3101 | 0e214bbe | Stavros Sachtouris | progress Build progress ✔ ✔ |
3102 | 0e214bbe | Stavros Sachtouris | metadata Custom server metadata ✔ ✔ |
3103 | 0e214bbe | Stavros Sachtouris | user_id Server owner **✘** ✔ |
3104 | 0e214bbe | Stavros Sachtouris | tenant_id Server tenant **✘** ✔ |
3105 | 0e214bbe | Stavros Sachtouris | accessIPv4 Server IPV4 net address **✘** ✔ |
3106 | 0e214bbe | Stavros Sachtouris | accessIPv6 Server IPV4 net address **✘** ✔ |
3107 | 0e214bbe | Stavros Sachtouris | addresses Nets connected on server **✘** ✔ |
3108 | 0e214bbe | Stavros Sachtouris | links Server links **✘** ✔ |
3109 | 0e214bbe | Stavros Sachtouris | ================ ========================== ======== ========== |
3110 | 0e214bbe | Stavros Sachtouris | |
3111 | 4935e468 | Stavros Sachtouris | * **status** values are described `here <#status-ref>`_ |
3112 | 0e214bbe | Stavros Sachtouris | |
3113 | 0e214bbe | Stavros Sachtouris | * **updated** and **created** are date-formated |
3114 | 0e214bbe | Stavros Sachtouris | |
3115 | 0e214bbe | Stavros Sachtouris | * **hostId** is always empty in Cyclades and is returned for compatibility reasons |
3116 | 0e214bbe | Stavros Sachtouris | |
3117 | 7b5eb6ff | Stavros Sachtouris | * **imageRef** and **flavorRef** always refer to existing Image and Flavor |
3118 | 7b5eb6ff | Stavros Sachtouris | specifications. Cyclades improved the OpenStack approach by using references |
3119 | 7b5eb6ff | Stavros Sachtouris | to Image and Flavor attributes, instead of listing their full properties |
3120 | 0e214bbe | Stavros Sachtouris | |
3121 | 7b5eb6ff | Stavros Sachtouris | * **adminPass** in Cyclades it is generated automatically during creation. For |
3122 | 7b5eb6ff | Stavros Sachtouris | safety, it is not stored anywhere in the system and it cannot be recovered |
3123 | 7b5eb6ff | Stavros Sachtouris | with a query request |
3124 | 0e214bbe | Stavros Sachtouris | |
3125 | 7b5eb6ff | Stavros Sachtouris | * **suspended** is True only of the server is suspended by the cloud |
3126 | 7b5eb6ff | Stavros Sachtouris | administrations or policy |
3127 | 0e214bbe | Stavros Sachtouris | |
3128 | 7b5eb6ff | Stavros Sachtouris | * **progress** is a number between 0 and 100 and reflects the server building |
3129 | 7b5eb6ff | Stavros Sachtouris | status |
3130 | 0e214bbe | Stavros Sachtouris | |
3131 | 7b5eb6ff | Stavros Sachtouris | * **metadata** are custom key:value pairs refering to the VM. In Cyclades, the |
3132 | 7b5eb6ff | Stavros Sachtouris | ``OS`` and ``users`` metadata are automatically retrieved from the servers |
3133 | 7b5eb6ff | Stavros Sachtouris | image during creation |
3134 | 0e214bbe | Stavros Sachtouris | |
3135 | 0e214bbe | Stavros Sachtouris | .. _status-ref: |
3136 | 0e214bbe | Stavros Sachtouris | |
3137 | 0e214bbe | Stavros Sachtouris | Server Status |
3138 | 0e214bbe | Stavros Sachtouris | ............. |
3139 | 0e214bbe | Stavros Sachtouris | |
3140 | 0e214bbe | Stavros Sachtouris | ============= ==================== ======== ========== |
3141 | 68386e00 | Stavros Sachtouris | Status Description Cyclades OS/Compute |
3142 | 0e214bbe | Stavros Sachtouris | ============= ==================== ======== ========== |
3143 | 0e214bbe | Stavros Sachtouris | BUILD Building ✔ ✔ |
3144 | 0e214bbe | Stavros Sachtouris | ACTIVE Up and running ✔ ✔ |
3145 | 0e214bbe | Stavros Sachtouris | STOPPED Shut down ✔ **✘** |
3146 | 0e214bbe | Stavros Sachtouris | REBOOT Rebooting ✔ ✔ |
3147 | 0e214bbe | Stavros Sachtouris | DELETED Removed ✔ ✔ |
3148 | 0e214bbe | Stavros Sachtouris | UNKNOWN Unexpected error ✔ ✔ |
3149 | 0e214bbe | Stavros Sachtouris | ERROR In error ✔ ✔ |
3150 | 0e214bbe | Stavros Sachtouris | HARD_REBOOT Hard rebooting **✘** ✔ |
3151 | 0e214bbe | Stavros Sachtouris | PASSWORD Resetting password **✘** ✔ |
3152 | 0e214bbe | Stavros Sachtouris | REBUILD Rebuilding server **✘** ✔ |
3153 | 0e214bbe | Stavros Sachtouris | RESCUE In rescue mode **✘** ✔ |
3154 | 0e214bbe | Stavros Sachtouris | RESIZE Resizing **✘** ✔ |
3155 | 0e214bbe | Stavros Sachtouris | REVERT_RESIZE Failed to resize **✘** ✔ |
3156 | 0e214bbe | Stavros Sachtouris | SHUTOFF Shut down by user **✘** ✔ |
3157 | 0e214bbe | Stavros Sachtouris | SUSPENDED Suspended **✘** ✔ |
3158 | 0e214bbe | Stavros Sachtouris | VERIFY_RESIZE Waiting confirmation **✘** ✔ |
3159 | 4935e468 | Stavros Sachtouris | ============= ==================== ======== ========== |
3160 | 4935e468 | Stavros Sachtouris | |
3161 | 7b5eb6ff | Stavros Sachtouris | .. _network-ref: |
3162 | 0ad49876 | Stavros Sachtouris | |
3163 | 0ad49876 | Stavros Sachtouris | Network |
3164 | 0ad49876 | Stavros Sachtouris | ....... |
3165 | 0ad49876 | Stavros Sachtouris | |
3166 | 68386e00 | Stavros Sachtouris | .. note:: Networks are features in Cyclades API but not in OS/Compute API |
3167 | 0ad49876 | Stavros Sachtouris | |
3168 | 0ad49876 | Stavros Sachtouris | ================== =========== |
3169 | 0ad49876 | Stavros Sachtouris | Network Attributes Description |
3170 | 0ad49876 | Stavros Sachtouris | ================== =========== |
3171 | 008c941f | Stavros Sachtouris | id Network identifier |
3172 | 008c941f | Stavros Sachtouris | name Network name |
3173 | 008c941f | Stavros Sachtouris | created Date of creation |
3174 | 008c941f | Stavros Sachtouris | updates Date of last update |
3175 | 008c941f | Stavros Sachtouris | cidr IPv4 CIDR Address |
3176 | 008c941f | Stavros Sachtouris | cidr6 IPv6 CIDR Address |
3177 | 008c941f | Stavros Sachtouris | dhcp IPv4 DHCP Address |
3178 | 008c941f | Stavros Sachtouris | dhcp6 IPv6 DHCP Address |
3179 | 008c941f | Stavros Sachtouris | gateway IPv4 Gateway Address |
3180 | 008c941f | Stavros Sachtouris | gateway6 IPv6 Gateway Address |
3181 | 008c941f | Stavros Sachtouris | public If the network is public |
3182 | 008c941f | Stavros Sachtouris | status Network status |
3183 | 008c941f | Stavros Sachtouris | attachments Network Interface Connections (NICs) |
3184 | 0ad49876 | Stavros Sachtouris | ================== =========== |
3185 | 0ad49876 | Stavros Sachtouris | |
3186 | 008c941f | Stavros Sachtouris | * **id** and **name** are int and string respectively |
3187 | 0ad49876 | Stavros Sachtouris | |
3188 | 0ad49876 | Stavros Sachtouris | * **created** and **updated** are ISO8061 date strings |
3189 | 0ad49876 | Stavros Sachtouris | |
3190 | 008c941f | Stavros Sachtouris | * **public** is a boolean flag |
3191 | 008c941f | Stavros Sachtouris | |
3192 | 008c941f | Stavros Sachtouris | * **status** can be PENDING, ACTIVE or DELETED |
3193 | 008c941f | Stavros Sachtouris | |
3194 | 0ad49876 | Stavros Sachtouris | * **attachments** refers to the NICs connecting servers on that network. |
3195 | 0ad49876 | Stavros Sachtouris | |
3196 | 4935e468 | Stavros Sachtouris | .. _nic-ref: |
3197 | 4935e468 | Stavros Sachtouris | |
3198 | 4935e468 | Stavros Sachtouris | Network Interface Connection (NIC) |
3199 | 4935e468 | Stavros Sachtouris | .................................. |
3200 | 4935e468 | Stavros Sachtouris | |
3201 | 7b5eb6ff | Stavros Sachtouris | A Network Interface Connection (NIC) represents a servers connection to a |
3202 | 7b5eb6ff | Stavros Sachtouris | network. |
3203 | 4935e468 | Stavros Sachtouris | |
3204 | 7b5eb6ff | Stavros Sachtouris | A NIC is identified by a server and an (obviously unique) mac address. A server |
3205 | 7b5eb6ff | Stavros Sachtouris | can have multiple NICs, though. In practice, a NIC id is used of reference and |
3206 | 7b5eb6ff | Stavros Sachtouris | identification. |
3207 | 4935e468 | Stavros Sachtouris | |
3208 | 7b5eb6ff | Stavros Sachtouris | Each NIC is used to connect a specific server to a network. The network is |
3209 | 7b5eb6ff | Stavros Sachtouris | aware of that connection for as long as it holds. If a NIC is disconnected from |
3210 | 7b5eb6ff | Stavros Sachtouris | a network, it is destroyed. |
3211 | 4935e468 | Stavros Sachtouris | |
3212 | 4935e468 | Stavros Sachtouris | A NIC specification contains the following information: |
3213 | 4935e468 | Stavros Sachtouris | |
3214 | 4935e468 | Stavros Sachtouris | ================= ====================== ======== ========== |
3215 | 68386e00 | Stavros Sachtouris | Server Attributes Description Cyclades OS/Compute |
3216 | 4935e468 | Stavros Sachtouris | ================= ====================== ======== ========== |
3217 | 4935e468 | Stavros Sachtouris | id The NIC id ✔ **✘** |
3218 | 4935e468 | Stavros Sachtouris | mac_address NIC's mac address ✔ **✘** |
3219 | 4935e468 | Stavros Sachtouris | network_id Network of connection ✔ **✘** |
3220 | 4935e468 | Stavros Sachtouris | firewallProfile The firewall profile ✔ **✘** |
3221 | 4935e468 | Stavros Sachtouris | ipv4 IP v4 address ✔ **✘** |
3222 | 4935e468 | Stavros Sachtouris | ipv6 IP v6 address ✔ **✘** |
3223 | 4935e468 | Stavros Sachtouris | ================= ====================== ======== ========== |
3224 | 4935e468 | Stavros Sachtouris | |
3225 | 7b5eb6ff | Stavros Sachtouris | * **id** is the unique identified of the NIC. It consists of the server id and |
3226 | 7b5eb6ff | Stavros Sachtouris | an ordinal number nic-<server-id>-<ordinal number> , e.g. for a server with |
3227 | 7b5eb6ff | Stavros Sachtouris | id 42:: |
3228 | 7b5eb6ff | Stavros Sachtouris | |
3229 | 7b5eb6ff | Stavros Sachtouris | nic-42-0, nic-42-1, ... |
3230 | 4935e468 | Stavros Sachtouris | |
3231 | 4935e468 | Stavros Sachtouris | * **mac_address** is the unique mac address of the interface |
3232 | 4935e468 | Stavros Sachtouris | |
3233 | 4935e468 | Stavros Sachtouris | * **network_id** is the id of the network this nic connects to. |
3234 | 4935e468 | Stavros Sachtouris | |
3235 | 7b5eb6ff | Stavros Sachtouris | * **firewallProfile** , if set, refers to the mode of the firewall. Valid |
3236 | 7b5eb6ff | Stavros Sachtouris | firewall profile values:: |
3237 | 4935e468 | Stavros Sachtouris | |
3238 | 7b5eb6ff | Stavros Sachtouris | ENABLED, DISABLED, PROTECTED |
3239 | 4935e468 | Stavros Sachtouris | |
3240 | 7b5eb6ff | Stavros Sachtouris | * **ipv4** and **ipv6** are the IP addresses (versions 4 and 6 respectively) of |
3241 | 7b5eb6ff | Stavros Sachtouris | the specific network connection for that machine. |
3242 | de2e08f6 | Stavros Sachtouris | |
3243 | de2e08f6 | Stavros Sachtouris | .. _flavor-ref: |
3244 | de2e08f6 | Stavros Sachtouris | |
3245 | de2e08f6 | Stavros Sachtouris | Flavor |
3246 | de2e08f6 | Stavros Sachtouris | ...... |
3247 | de2e08f6 | Stavros Sachtouris | |
3248 | de2e08f6 | Stavros Sachtouris | A flavor is a hardware configuration for a server. It contains the following |
3249 | de2e08f6 | Stavros Sachtouris | information: |
3250 | de2e08f6 | Stavros Sachtouris | |
3251 | de2e08f6 | Stavros Sachtouris | ================= ==================== ======== ========== |
3252 | 68386e00 | Stavros Sachtouris | Flavor Attributes Description Cyclades OS/Compute |
3253 | de2e08f6 | Stavros Sachtouris | ================= ==================== ======== ========== |
3254 | de2e08f6 | Stavros Sachtouris | id The flavor id ✔ ✔ |
3255 | de2e08f6 | Stavros Sachtouris | name The flavor name ✔ ✔ |
3256 | de2e08f6 | Stavros Sachtouris | ram Server RAM size ✔ ✔ |
3257 | de2e08f6 | Stavros Sachtouris | SNF:disk_template Storage mechanism ✔ **✘** |
3258 | de2e08f6 | Stavros Sachtouris | disk Server disk size ✔ ✔ |
3259 | de2e08f6 | Stavros Sachtouris | cpu # of Virtual CPUs ✔ **✘** |
3260 | de2e08f6 | Stavros Sachtouris | vcpus # of Virtual CPUs **✘** ✔ |
3261 | de2e08f6 | Stavros Sachtouris | links rel Atom link rel field **✘** ✔ |
3262 | de2e08f6 | Stavros Sachtouris | links href Atom link href field **✘** ✔ |
3263 | de2e08f6 | Stavros Sachtouris | ================= ==================== ======== ========== |
3264 | de2e08f6 | Stavros Sachtouris | |
3265 | de2e08f6 | Stavros Sachtouris | * **id** is the flavor unique id (a possitive integer) |
3266 | de2e08f6 | Stavros Sachtouris | |
3267 | de2e08f6 | Stavros Sachtouris | * **name** is the flavor name (a string) |
3268 | de2e08f6 | Stavros Sachtouris | |
3269 | de2e08f6 | Stavros Sachtouris | * **ram** is the server RAM size in MB |
3270 | de2e08f6 | Stavros Sachtouris | |
3271 | 7b5eb6ff | Stavros Sachtouris | * **SNF:disk_template** is a reference to the underlying storage mechanism |
3272 | 7b5eb6ff | Stavros Sachtouris | used by the Cyclades server. It is Cyclades specific. |
3273 | de2e08f6 | Stavros Sachtouris | |
3274 | de2e08f6 | Stavros Sachtouris | * **disk** the servers disk size in GB |
3275 | de2e08f6 | Stavros Sachtouris | |
3276 | 7b5eb6ff | Stavros Sachtouris | * **cpu** and **vcpus** are semantically equivalent terms in Cyclades and |
3277 | 7b5eb6ff | Stavros Sachtouris | OS/Compute APIs respectively and they refer to the number of virtual CPUs |
3278 | 7b5eb6ff | Stavros Sachtouris | assigned to a server |
3279 | de2e08f6 | Stavros Sachtouris | |
3280 | de2e08f6 | Stavros Sachtouris | * **link ref** and **link href** refer to the Atom link attributes that are |
3281 | 7b5eb6ff | Stavros Sachtouris | `used in OS/Compute API <http://docs.openstack.org/api/openstack-compute/2/content/List_Flavors-d1e4188.html>`_. |
3282 | f76ec11f | Stavros Sachtouris | |
3283 | f76ec11f | Stavros Sachtouris | .. _image-ref: |
3284 | f76ec11f | Stavros Sachtouris | |
3285 | f76ec11f | Stavros Sachtouris | Image |
3286 | f76ec11f | Stavros Sachtouris | ..... |
3287 | f76ec11f | Stavros Sachtouris | |
3288 | f76ec11f | Stavros Sachtouris | An image is a collection of files you use to create or rebuild a server. |
3289 | f76ec11f | Stavros Sachtouris | |
3290 | f76ec11f | Stavros Sachtouris | An image item may have the fields presented bellow: |
3291 | f76ec11f | Stavros Sachtouris | |
3292 | f76ec11f | Stavros Sachtouris | ================= ====================== ======== ========== |
3293 | 68386e00 | Stavros Sachtouris | Server Attributes Description Cyclades OS/Compute |
3294 | f76ec11f | Stavros Sachtouris | ================= ====================== ======== ========== |
3295 | f76ec11f | Stavros Sachtouris | id Image ID ✔ ✔ |
3296 | f76ec11f | Stavros Sachtouris | name Image name ✔ ✔ |
3297 | f76ec11f | Stavros Sachtouris | updated Last update date ✔ ✔ |
3298 | f76ec11f | Stavros Sachtouris | created Image creation date ✔ ✔ |
3299 | f76ec11f | Stavros Sachtouris | progress Ready status progress ✔ **✘** |
3300 | f76ec11f | Stavros Sachtouris | status Image status **✘** ✔ |
3301 | f76ec11f | Stavros Sachtouris | tenant_id Image creator **✘** ✔ |
3302 | f76ec11f | Stavros Sachtouris | user_id Image users **✘** ✔ |
3303 | f76ec11f | Stavros Sachtouris | metadata Custom metadata ✔ ✔ |
3304 | f76ec11f | Stavros Sachtouris | links Atom links **✘** ✔ |
3305 | f76ec11f | Stavros Sachtouris | minDisk Minimum required disk **✘** ✔ |
3306 | f76ec11f | Stavros Sachtouris | minRam Minimum required RAM **✘** ✔ |
3307 | f76ec11f | Stavros Sachtouris | ================= ====================== ======== ========== |
3308 | f76ec11f | Stavros Sachtouris | |
3309 | f76ec11f | Stavros Sachtouris | * **id** is the image id and **name** is the image name. They are both strings. |
3310 | f76ec11f | Stavros Sachtouris | |
3311 | f76ec11f | Stavros Sachtouris | * **updated** and **created** are both ISO8601 date strings |
3312 | f76ec11f | Stavros Sachtouris | |
3313 | f76ec11f | Stavros Sachtouris | * **progress** varies between 0 and 100 and denotes the status of the image |
3314 | f76ec11f | Stavros Sachtouris | |
3315 | f76ec11f | Stavros Sachtouris | * **metadata** is a collection of ``key``:``values`` pairs of custom metadata, |
3316 | 7b5eb6ff | Stavros Sachtouris | under the tag ``values`` which lies under the tag ``metadata``. |
3317 | f76ec11f | Stavros Sachtouris | |
3318 | 68386e00 | Stavros Sachtouris | .. note:: in OS/Compute, the ``values`` layer is missing |