Rebuild server
Method | URI | Description |
---|---|---|
POST | /v2/{tenant_id}/servers/{server_id}/action | 指定したサーバを再構築します。リクエストボディ部でrebuildアクションを指定してください。 |
Normal response codes: 202
Request
下表は、サーバ再構築リクエストのURIパラメーターの一覧です。
Name | Type | Description |
---|---|---|
{tenant_id} | UUID | プロジェクトID |
{server_id} | UUID | 仮想サーバID |
下表は、仮想サーバ再構築リクエストのボディ部のパラメーターの一覧です。
Name | Type | Description |
---|---|---|
imageRef | string | 仮想サーバに適用するイメージのUUID |
name | string
(Optional) |
新しいサーバの名前 |
metadata | string
(Optional) |
メタデータキーと値のペア。メタデータキーと値の最大サイズはそれぞれ、255バイトです。 |
Example. Rebuild server: JSON request
{
"rebuild": {
"imageRef": "70a599e0-31e7-49b7-b260-868f441e862b",
"name": "foobar",
"adminPass": "seekr3t",
"accessIPv4": "1.2.3.4",
"accessIPv6": "fe80::100",
"metadata": {
"meta var": "meta val"
}
}
}
Response
下表は、仮想サーバ再構築レスポンスのヘッダーパラメーターの一覧です。
Name | Type | Description |
---|---|---|
Location | AnyURI
(Required) |
再構築する仮想サーバの具体的なURL |
Example. Rebuild server: JSON response
{
"server": {
"accessIPv4": "1.2.3.4",
"accessIPv6": "fe80::100",
"addresses": {
"private": [
{
"addr": "192.168.0.3",
"version": 4
}
]
},
"adminPass": "seekr3t",
"created": "2012-09-12T17:20:36Z",
"flavor": {
"id": "1",
"links": [
{
"href": "http://openstack.example.com/openstack/flavors/1",
"rel": "bookmark"
}
]
},
"hostId": "1e3da81662354c25560b7e5ea6d8123031f67168b6992f20bb84df69",
"id": "075e40fe-9f03-4652-ba8e-5f8e2547899a",
"image": {
"id": "70a599e0-31e7-49b7-b260-868f441e862b",
"links": [
{
"href": "http://openstack.example.com/openstack/images/70a599e0-31e7-49b7-b260-868f441e862b",
"rel": "bookmark"
}
]
},
"links": [
{
"href": "http://openstack.example.com/v2/openstack/servers/075e40fe-9f03-4652-ba8e-5f8e2547899a",
"rel": "self"
},
{
"href": "http://openstack.example.com/openstack/servers/075e40fe-9f03-4652-ba8e-5f8e2547899a",
"rel": "bookmark"
}
],
"metadata": {
"meta var": "meta val"
},
"name": "foobar",
"progress": 0,
"status": "ACTIVE",
"tenant_id": "openstack",
"updated": "2012-09-12T17:20:37Z",
"user_id": "fake"
}
}