From a9add7d35e27b90f0c420d2b24b1af88b978fd7b Mon Sep 17 00:00:00 2001 From: Dan Smith Date: Tue, 12 Feb 2013 15:45:24 -0500 Subject: Add support for network adapter hotplug. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch makes it possible to add/del instance interface other than booting time. Implement bp:network-adapter-hotplug Originally from change Ibee003a9ec6cc9b3fd275417caccd0c67f6c871f Co-authored-by: Yaguang Tang Co-authored-by: Édouard Thuleau Change-Id: I4f8f677af58afcb928379e5cf859388d1da45d51 --- .../all_extensions/extensions-get-resp.json | 12 ++++++++++-- .../all_extensions/extensions-get-resp.xml | 7 +++++-- .../attach-interfaces-create-req.json | 5 +++++ .../attach-interfaces-create-req.xml | 4 ++++ .../attach-interfaces-create-resp.json | 12 ++++++++++++ .../attach-interfaces-create-resp.xml | 13 +++++++++++++ .../attach-interfaces-list-resp.json | 16 ++++++++++++++++ .../attach-interfaces-list-resp.xml | 15 +++++++++++++++ .../os-attach-interfaces/attach-interfaces-list.xml | 17 +++++++++++++++++ .../attach-interfaces-show-resp.json | 14 ++++++++++++++ .../attach-interfaces-show-resp.xml | 13 +++++++++++++ .../os-attach-interfaces/server-post-req.json | 16 ++++++++++++++++ .../os-attach-interfaces/server-post-req.xml | 19 +++++++++++++++++++ .../os-attach-interfaces/server-post-resp.json | 16 ++++++++++++++++ .../os-attach-interfaces/server-post-resp.xml | 6 ++++++ 15 files changed, 181 insertions(+), 4 deletions(-) create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.json create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.xml create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.json create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.xml create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.json create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.xml create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-list.xml create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.json create mode 100644 doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.xml create mode 100644 doc/api_samples/os-attach-interfaces/server-post-req.json create mode 100644 doc/api_samples/os-attach-interfaces/server-post-req.xml create mode 100644 doc/api_samples/os-attach-interfaces/server-post-resp.json create mode 100644 doc/api_samples/os-attach-interfaces/server-post-resp.xml (limited to 'doc') diff --git a/doc/api_samples/all_extensions/extensions-get-resp.json b/doc/api_samples/all_extensions/extensions-get-resp.json index ba5e410eb..0009c5e83 100644 --- a/doc/api_samples/all_extensions/extensions-get-resp.json +++ b/doc/api_samples/all_extensions/extensions-get-resp.json @@ -96,6 +96,14 @@ "namespace": "http://docs.openstack.org/compute/ext/aggregates/api/v1.1", "updated": "2012-01-12T00:00:00+00:00" }, + { + "alias": "os-attach-interfaces", + "description": "Attach interface support.", + "links": [], + "name": "AttachInterfaces", + "namespace": "http://docs.openstack.org/compute/ext/interfaces/api/v1.1", + "updated": "2012-07-22T00:00:00+00:00" + }, { "alias": "os-availability-zone", "description": "1. Add availability_zone to the Create Server v1.1 API.\n 2. Add availability zones describing.\n ", @@ -194,11 +202,11 @@ }, { "alias": "os-evacuate", - "description": "Enables server evacuation", + "description": "Enables server evacuation.", "links": [], "name": "Evacuate", "namespace": "http://docs.openstack.org/compute/ext/evacuate/api/v2", - "updated": "2012-12-05T00:00:00+00:00" + "updated": "2013-01-06T00:00:00+00:00" }, { "alias": "os-fixed-ips", diff --git a/doc/api_samples/all_extensions/extensions-get-resp.xml b/doc/api_samples/all_extensions/extensions-get-resp.xml index a18e52437..d479d09b5 100644 --- a/doc/api_samples/all_extensions/extensions-get-resp.xml +++ b/doc/api_samples/all_extensions/extensions-get-resp.xml @@ -40,6 +40,9 @@ Admin-only aggregate administration. + + Attach interface support. + 1. Add availability_zone to the Create Server v1.1 API. 2. Add availability zones describing. @@ -88,8 +91,8 @@ Instance deferred delete. - - Enables server evacuation + + Enables server evacuation. Fixed IPs support. diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.json b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.json new file mode 100644 index 000000000..11dcf6437 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.json @@ -0,0 +1,5 @@ +{ + "interfaceAttachment": { + "port_id": "ce531f90-199f-48c0-816c-13e38010b442" + } +} diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.xml b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.xml new file mode 100644 index 000000000..bd3f24265 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-req.xml @@ -0,0 +1,4 @@ + + + ce531f90-199f-48c0-816c-13e38010b442 + \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.json b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.json new file mode 100644 index 000000000..309f2a1e8 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.json @@ -0,0 +1,12 @@ +{ + "interfaceAttachment": { + "fixed_ips": [{ + "ip_address": "192.168.1.1", + "subnet_id": "f8a6e8f8-c2ec-497c-9f23-da9616de54ef" + }], + "mac_addr": "fa:16:3e:4c:2c:30", + "net_id": "3cb9bc59-5699-4588-a4b1-b87f96708bc6", + "port_id": "ce531f90-199f-48c0-816c-13e38010b442", + "port_state": "ACTIVE" + } +} diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.xml b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.xml new file mode 100644 index 000000000..4b3254371 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-create-resp.xml @@ -0,0 +1,13 @@ + + + 3cb9bc59-5699-4588-a4b1-b87f96708bc6 + ce531f90-199f-48c0-816c-13e38010b442 + + + f8a6e8f8-c2ec-497c-9f23-da9616de54ef + 192.168.1.3 + + + ACTIVE + fa:16:3e:4c:2c:30 + \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.json b/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.json new file mode 100644 index 000000000..2c62ef9d5 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.json @@ -0,0 +1,16 @@ +{ + "interfaceAttachments": [ + { + "port_state": "ACTIVE", + "fixed_ips": [ + { + "subnet_id": "f8a6e8f8-c2ec-497c-9f23-da9616de54ef", + "ip_address": "192.168.1.3" + } + ], + "net_id": "3cb9bc59-5699-4588-a4b1-b87f96708bc6", + "port_id": "ce531f90-199f-48c0-816c-13e38010b442", + "mac_addr": "fa:16:3e:4c:2c:30" + } + ] +} diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.xml b/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.xml new file mode 100644 index 000000000..f1bef407c --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-list-resp.xml @@ -0,0 +1,15 @@ + + + + ACTIVE + + + f8a6e8f8-c2ec-497c-9f23-da9616de54ef + 192.168.1.3 + + + ce531f90-199f-48c0-816c-13e38010b442 + 3cb9bc59-5699-4588-a4b1-b87f96708bc6 + fa:16:3e:4c:2c:30 + + \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-list.xml b/doc/api_samples/os-attach-interfaces/attach-interfaces-list.xml new file mode 100644 index 000000000..3392e2cc6 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-list.xml @@ -0,0 +1,17 @@ + + + + + ACTIVE + + + f8a6e8f8-c2ec-497c-9f23-da9616de54ef + 192.168.1.3 + + + ce531f90-199f-48c0-816c-13e38010b442 + 3cb9bc59-5699-4588-a4b1-b87f96708bc6 + fa:16:3e:4c:2c:30 + + + diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.json b/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.json new file mode 100644 index 000000000..14f5b9e1e --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.json @@ -0,0 +1,14 @@ +{ + "interfaceAttachment": { + "port_state": "ACTIVE", + "fixed_ips": [ + { + "subnet_id": "f8a6e8f8-c2ec-497c-9f23-da9616de54ef", + "ip_address": "192.168.1.3" + } + ], + "net_id": "3cb9bc59-5699-4588-a4b1-b87f96708bc6", + "port_id": "ce531f90-199f-48c0-816c-13e38010b442", + "mac_addr": "fa:16:3e:4c:2c:30" + } +} diff --git a/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.xml b/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.xml new file mode 100644 index 000000000..ce3e2fec2 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/attach-interfaces-show-resp.xml @@ -0,0 +1,13 @@ + + + ACTIVE + + + b6e47749-6bf0-4d6e-ae4b-ba6b5e238510 + 192.168.123.131 + + + 89e64f2e-86bd-4c19-9155-4548b36fdcb2 + a9efd207-2c1a-4cdd-a296-d3c7c3211302 + fa:16:3e:a4:1c:12 + diff --git a/doc/api_samples/os-attach-interfaces/server-post-req.json b/doc/api_samples/os-attach-interfaces/server-post-req.json new file mode 100644 index 000000000..d88eb4122 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/server-post-req.json @@ -0,0 +1,16 @@ +{ + "server" : { + "name" : "new-server-test", + "imageRef" : "http://openstack.example.com/openstack/images/70a599e0-31e7-49b7-b260-868f441e862b", + "flavorRef" : "http://openstack.example.com/openstack/flavors/1", + "metadata" : { + "My Server Name" : "Apache1" + }, + "personality" : [ + { + "path" : "/etc/banner.txt", + "contents" : "ICAgICAgDQoiQSBjbG91ZCBkb2VzIG5vdCBrbm93IHdoeSBpdCBtb3ZlcyBpbiBqdXN0IHN1Y2ggYSBkaXJlY3Rpb24gYW5kIGF0IHN1Y2ggYSBzcGVlZC4uLkl0IGZlZWxzIGFuIGltcHVsc2lvbi4uLnRoaXMgaXMgdGhlIHBsYWNlIHRvIGdvIG5vdy4gQnV0IHRoZSBza3kga25vd3MgdGhlIHJlYXNvbnMgYW5kIHRoZSBwYXR0ZXJucyBiZWhpbmQgYWxsIGNsb3VkcywgYW5kIHlvdSB3aWxsIGtub3csIHRvbywgd2hlbiB5b3UgbGlmdCB5b3Vyc2VsZiBoaWdoIGVub3VnaCB0byBzZWUgYmV5b25kIGhvcml6b25zLiINCg0KLVJpY2hhcmQgQmFjaA==" + } + ] + } +} \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/server-post-req.xml b/doc/api_samples/os-attach-interfaces/server-post-req.xml new file mode 100644 index 000000000..0a3c8bb53 --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/server-post-req.xml @@ -0,0 +1,19 @@ + + + + Apache1 + + + + ICAgICAgDQoiQSBjbG91ZCBkb2VzIG5vdCBrbm93IHdoeSBp + dCBtb3ZlcyBpbiBqdXN0IHN1Y2ggYSBkaXJlY3Rpb24gYW5k + IGF0IHN1Y2ggYSBzcGVlZC4uLkl0IGZlZWxzIGFuIGltcHVs + c2lvbi4uLnRoaXMgaXMgdGhlIHBsYWNlIHRvIGdvIG5vdy4g + QnV0IHRoZSBza3kga25vd3MgdGhlIHJlYXNvbnMgYW5kIHRo + ZSBwYXR0ZXJucyBiZWhpbmQgYWxsIGNsb3VkcywgYW5kIHlv + dSB3aWxsIGtub3csIHRvbywgd2hlbiB5b3UgbGlmdCB5b3Vy + c2VsZiBoaWdoIGVub3VnaCB0byBzZWUgYmV5b25kIGhvcml6 + b25zLiINCg0KLVJpY2hhcmQgQmFjaA== + + + \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/server-post-resp.json b/doc/api_samples/os-attach-interfaces/server-post-resp.json new file mode 100644 index 000000000..54e47aefa --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/server-post-resp.json @@ -0,0 +1,16 @@ +{ + "server": { + "adminPass": "N4Lxd6cMUXmE", + "id": "4e44ac84-f3ed-4219-aa2e-b3d1477f0ac3", + "links": [ + { + "href": "http://openstack.example.com/v2/openstack/servers/4e44ac84-f3ed-4219-aa2e-b3d1477f0ac3", + "rel": "self" + }, + { + "href": "http://openstack.example.com/openstack/servers/4e44ac84-f3ed-4219-aa2e-b3d1477f0ac3", + "rel": "bookmark" + } + ] + } +} \ No newline at end of file diff --git a/doc/api_samples/os-attach-interfaces/server-post-resp.xml b/doc/api_samples/os-attach-interfaces/server-post-resp.xml new file mode 100644 index 000000000..0efd9029d --- /dev/null +++ b/doc/api_samples/os-attach-interfaces/server-post-resp.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file -- cgit