profitbricks 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (108) hide show
  1. data/.autotest +23 -0
  2. data/.gemtest +0 -0
  3. data/.rspec +3 -0
  4. data/CHANGELOG.md +6 -0
  5. data/Gemfile +8 -0
  6. data/Gemfile.lock +53 -0
  7. data/Manifest.txt +106 -0
  8. data/README.md +70 -0
  9. data/Rakefile +31 -0
  10. data/bin/profitbricks +3 -0
  11. data/examples/create_datacenter.rb +57 -0
  12. data/lib/profitbricks/config.rb +16 -0
  13. data/lib/profitbricks/data_center.rb +100 -0
  14. data/lib/profitbricks/extensions.rb +9 -0
  15. data/lib/profitbricks/image.rb +47 -0
  16. data/lib/profitbricks/ip_block.rb +49 -0
  17. data/lib/profitbricks/model.rb +102 -0
  18. data/lib/profitbricks/nic.rb +103 -0
  19. data/lib/profitbricks/profitbricks.rb +86 -0
  20. data/lib/profitbricks/server.rb +83 -0
  21. data/lib/profitbricks/storage.rb +84 -0
  22. data/lib/profitbricks.rb +15 -0
  23. data/profitbricks.gemspec +34 -0
  24. data/spec/fixtures/add_public_ip_to_nic/success.json +10 -0
  25. data/spec/fixtures/add_public_ip_to_nic/success.xml +1 -0
  26. data/spec/fixtures/clear_data_center/success.json +10 -0
  27. data/spec/fixtures/clear_data_center/success.xml +1 -0
  28. data/spec/fixtures/connect_storage_to_server/success.json +10 -0
  29. data/spec/fixtures/connect_storage_to_server/success.xml +1 -0
  30. data/spec/fixtures/create_data_center/success.json +10 -0
  31. data/spec/fixtures/create_data_center/success.xml +1 -0
  32. data/spec/fixtures/create_nic/success.json +11 -0
  33. data/spec/fixtures/create_nic/success.xml +1 -0
  34. data/spec/fixtures/create_server/minimal.json +11 -0
  35. data/spec/fixtures/create_server/minimal.xml +1 -0
  36. data/spec/fixtures/create_storage/success.json +11 -0
  37. data/spec/fixtures/create_storage/success.xml +1 -0
  38. data/spec/fixtures/delete_data_center/success.json +8 -0
  39. data/spec/fixtures/delete_data_center/success.xml +1 -0
  40. data/spec/fixtures/delete_nic/success.json +10 -0
  41. data/spec/fixtures/delete_nic/success.xml +1 -0
  42. data/spec/fixtures/delete_server/success.json +10 -0
  43. data/spec/fixtures/delete_server/success.xml +1 -0
  44. data/spec/fixtures/delete_storage/failture.json +16 -0
  45. data/spec/fixtures/delete_storage/failture.xml +1 -0
  46. data/spec/fixtures/delete_storage/success.json +10 -0
  47. data/spec/fixtures/delete_storage/success.xml +1 -0
  48. data/spec/fixtures/disconnect_storage_from_server/failture.json +16 -0
  49. data/spec/fixtures/disconnect_storage_from_server/failture.xml +1 -0
  50. data/spec/fixtures/disconnect_storage_from_server/success.json +10 -0
  51. data/spec/fixtures/disconnect_storage_from_server/success.xml +1 -0
  52. data/spec/fixtures/get_all_data_centers/empty.json +1 -0
  53. data/spec/fixtures/get_all_data_centers/empty.xml +1 -0
  54. data/spec/fixtures/get_all_data_centers/test_datacenter.json +10 -0
  55. data/spec/fixtures/get_all_data_centers/test_datacenter.xml +1 -0
  56. data/spec/fixtures/get_all_images/success.json +100 -0
  57. data/spec/fixtures/get_all_images/success.xml +1 -0
  58. data/spec/fixtures/get_all_public_ip_blocks/success.json +16 -0
  59. data/spec/fixtures/get_all_public_ip_blocks/success.xml +1 -0
  60. data/spec/fixtures/get_data_center/create.json +147 -0
  61. data/spec/fixtures/get_data_center/create.xml +1 -0
  62. data/spec/fixtures/get_data_center/two_servers_with_storage.json +147 -0
  63. data/spec/fixtures/get_data_center/two_servers_with_storage.xml +1 -0
  64. data/spec/fixtures/get_data_center_state/in_process.json +1 -0
  65. data/spec/fixtures/get_data_center_state/in_process.xml +1 -0
  66. data/spec/fixtures/get_data_center_state/success.json +1 -0
  67. data/spec/fixtures/get_data_center_state/success.xml +1 -0
  68. data/spec/fixtures/get_image/success.json +15 -0
  69. data/spec/fixtures/get_image/success.xml +1 -0
  70. data/spec/fixtures/get_nic/success.json +16 -0
  71. data/spec/fixtures/get_nic/success.xml +1 -0
  72. data/spec/fixtures/get_nic/two_ips.json +19 -0
  73. data/spec/fixtures/get_nic/two_ips.xml +1 -0
  74. data/spec/fixtures/get_server/after_create.json +17 -0
  75. data/spec/fixtures/get_server/after_create.xml +1 -0
  76. data/spec/fixtures/get_server/connected_storage.json +26 -0
  77. data/spec/fixtures/get_server/connected_storage.xml +1 -0
  78. data/spec/fixtures/get_storage/success.json +14 -0
  79. data/spec/fixtures/get_storage/success.xml +1 -0
  80. data/spec/fixtures/reboot_server/success.json +1 -0
  81. data/spec/fixtures/reboot_server/success.xml +1 -0
  82. data/spec/fixtures/release_public_ip_block/success.json +1 -0
  83. data/spec/fixtures/release_public_ip_block/success.xml +1 -0
  84. data/spec/fixtures/remove_public_ip_from_nic/success.json +10 -0
  85. data/spec/fixtures/remove_public_ip_from_nic/success.xml +1 -0
  86. data/spec/fixtures/reserve_public_ip_block/success.json +13 -0
  87. data/spec/fixtures/reserve_public_ip_block/success.xml +1 -0
  88. data/spec/fixtures/set_image_os_type/success.json +1 -0
  89. data/spec/fixtures/set_image_os_type/success.xml +1 -0
  90. data/spec/fixtures/set_internet_access/success.json +10 -0
  91. data/spec/fixtures/set_internet_access/success.xml +1 -0
  92. data/spec/fixtures/update_data_center/success.json +10 -0
  93. data/spec/fixtures/update_data_center/success.xml +1 -0
  94. data/spec/fixtures/update_nic/success.json +10 -0
  95. data/spec/fixtures/update_nic/success.xml +1 -0
  96. data/spec/fixtures/update_server/basic.json +10 -0
  97. data/spec/fixtures/update_server/basic.xml +1 -0
  98. data/spec/fixtures/update_storage/success.json +10 -0
  99. data/spec/fixtures/update_storage/success.xml +1 -0
  100. data/spec/profitbricks/data_center_spec.rb +95 -0
  101. data/spec/profitbricks/image_spec.rb +23 -0
  102. data/spec/profitbricks/ip_block_spec.rb +26 -0
  103. data/spec/profitbricks/model_spec.rb +68 -0
  104. data/spec/profitbricks/nic_spec.rb +55 -0
  105. data/spec/profitbricks/server_spec.rb +41 -0
  106. data/spec/profitbricks/storage_spec.rb +47 -0
  107. data/spec/spec_helper.rb +45 -0
  108. metadata +193 -0
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getAllImagesResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><cpuHotpluggable>false</cpuHotpluggable><imageId>5f58656e-66c3-11e1-8c6f-0025901dfe2a</imageId><imageName>Windows8-ConsumerPreview-64bit-English.iso</imageName><imageSize>6</imageSize><imageType>CDROM</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>UNKNOWN</osType><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>9de62e6e-ff1c-11e0-a1a7-0025901dfe2a</imageId><imageName>grml64_2011.05.iso</imageName><imageSize>698</imageSize><imageType>CDROM</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>OTHER</osType><serverIds>cab5b774-b33d-2027-eae1-85d58adeb5e8</serverIds><serverIds>b09cc7b2-fcc7-16de-88c7-0ddd7c5aefff</serverIds><serverIds>ccbc8485-35cd-2d62-016a-a1f74557b379</serverIds><serverIds>6a9160c9-c1f6-5464-d894-720b9c75e369</serverIds><serverIds>c9c01a18-d7c1-6c4c-4cbc-f8711cf52b20</serverIds><serverIds>805eae83-595f-925d-8621-d4cbd1f4686a</serverIds><serverIds>1180df13-b753-4ed1-5b40-37ee02c1a9b4</serverIds><serverIds>997d954e-6c64-4255-a9a6-345b01956959</serverIds><serverIds>c7a9af7d-7626-7b44-4e96-21d03ca424bd</serverIds><serverIds>f04b39f4-afcf-b3b3-dc63-21c4b7c96648</serverIds><serverIds>1f924812-3e58-2085-a861-42c5fb7f0cce</serverIds><serverIds>7b77d8dc-f7e1-b59d-5939-0ed48749954e</serverIds><serverIds>4dfc0b6b-9f47-1d8f-43c5-0b8588300715</serverIds><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>3fbd84d1-226d-11e1-a5a8-0025901e3c62</imageId><imageName>WinPE-VirtIO-Driver.iso</imageName><imageSize>247</imageSize><imageType>CDROM</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>WINDOWS</osType><serverIds>cb12122a-c52b-62e4-44c4-dae11e26cb93</serverIds><serverIds>eb1bac3c-e93b-3a5b-a2e4-306fa96a37cc</serverIds><serverIds>1f5fe5fc-6941-4829-9a0e-c3954aa86d22</serverIds><serverIds>6cbe83ff-b504-601b-1008-d88b15108116</serverIds><serverIds>e4a997b4-4f6f-6dff-7eef-aa93a0f1f42a</serverIds><serverIds>b61c8de3-f636-727d-7d11-2f7eb1dd7098</serverIds><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>d09207ec-2be2-11e1-9cf2-0025901dfe2a</imageId><imageName>PB-Win2012-Preview-EN-RDP.img</imageName><imageSize>13312</imageSize><imageType>HDD</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>WINDOWS</osType><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>d1d8747f-fa56-11e0-a1a7-0025901dfe2a</imageId><imageName>profitbricks-debian-squeeze-EN-6.0.1a-amd64.img</imageName><imageSize>1024</imageSize><imageType>HDD</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>OTHER</osType><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>1cf5f820-58cc-11e1-9e36-0025901dfe2a</imageId><imageName>PB-Win-2008-R2-DE-RDP-2.12.img</imageName><imageSize>9216</imageSize><imageType>HDD</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>WINDOWS</osType><writeable>true</writeable></return><return><cpuHotpluggable>false</cpuHotpluggable><imageId>5256ccd8-58c4-11e1-9e36-0025901dfe2a</imageId><imageName>PB-Win-2008-R2-EN-RDP-2.12.img</imageName><imageSize>8704</imageSize><imageType>HDD</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>WINDOWS</osType><writeable>true</writeable></return></ns2:getAllImagesResponse></S:Body></S:Envelope>
@@ -0,0 +1,16 @@
1
+ {
2
+ "get_all_public_ip_blocks_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "block_id": "167bc48c-4f80-4870-b5db-13d7d762e1cd",
6
+ "public_ips": [
7
+ {
8
+ "ip": "46.16.74.12"
9
+ },
10
+ {
11
+ "ip": "46.16.74.13"
12
+ }
13
+ ]
14
+ }
15
+ }
16
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getAllPublicIpBlocksResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><blockId>167bc48c-4f80-4870-b5db-13d7d762e1cd</blockId><publicIps><ip>46.16.74.12</ip></publicIps><publicIps><ip>46.16.74.13</ip></publicIps></return></ns2:getAllPublicIpBlocksResponse></S:Body></S:Envelope>
@@ -0,0 +1,147 @@
1
+ {
2
+ "get_data_center_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
6
+ "data_center_name": "Test",
7
+ "data_center_version": "9",
8
+ "provisioning_state": "AVAILABLE",
9
+ "servers": [
10
+ {
11
+ "connected_storages": {
12
+ "bus_type": "VIRTIO",
13
+ "device_number": "1",
14
+ "size": "5",
15
+ "storage_id": "b6fdfa5b-fadf-5621-1be3-0882822abb88",
16
+ "storage_name": "Debian"
17
+ },
18
+ "cores": "1",
19
+ "creation_time": "2012-03-03T23:28:44+01:00",
20
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
21
+ "data_center_version": "9",
22
+ "internet_access": false,
23
+ "ips": "10.7.232.12",
24
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
25
+ "nics": {
26
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
27
+ "data_center_version": "9",
28
+ "firewall": {
29
+ "active": false,
30
+ "firewall_id": "374da20a-e7a4-151a-0be8-04c5b82409a0",
31
+ "nic_id": "8c5758c1-29b7-8a23-ffc8-4c54dac405c2",
32
+ "provisioning_state": "AVAILABLE"
33
+ },
34
+ "internet_access": false,
35
+ "ips": "10.7.232.12",
36
+ "lan_id": "1",
37
+ "mac_address": "02:01:eb:58:b1:63",
38
+ "nic_id": "8c5758c1-29b7-8a23-ffc8-4c54dac405c2",
39
+ "nic_name": "eth0",
40
+ "server_id": "7e132ddb-b2c8-a109-7f99-7b4a32955006"
41
+ },
42
+ "os_type": "OTHER",
43
+ "provisioning_state": "AVAILABLE",
44
+ "ram": "256",
45
+ "server_id": "7e132ddb-b2c8-a109-7f99-7b4a32955006",
46
+ "server_name": "Test Server 2",
47
+ "virtual_machine_state": "RUNNING"
48
+ },
49
+ {
50
+ "connected_storages": {
51
+ "bus_type": "VIRTIO",
52
+ "device_number": "1",
53
+ "size": "1",
54
+ "storage_id": "68f1badb-edbf-bb49-00cd-b5481ac91f7f",
55
+ "storage_name": "Empty"
56
+ },
57
+ "cores": "1",
58
+ "creation_time": "2012-03-02T15:40:24+01:00",
59
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
60
+ "data_center_version": "9",
61
+ "internet_access": true,
62
+ "ips": [
63
+ "10.7.232.11",
64
+ "46.16.73.186"
65
+ ],
66
+ "last_modification_time": "2012-03-02T15:57:31+01:00",
67
+ "nics": [
68
+ {
69
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
70
+ "data_center_version": "9",
71
+ "firewall": {
72
+ "active": false,
73
+ "firewall_id": "dac45569-b53a-c270-20c8-aa69aa071d28",
74
+ "nic_id": "30790131-39f1-dd1c-c457-3e8ed77e74f6",
75
+ "provisioning_state": "AVAILABLE"
76
+ },
77
+ "internet_access": true,
78
+ "ips": "46.16.73.186",
79
+ "lan_id": "2",
80
+ "mac_address": "02:01:17:75:f9:cb",
81
+ "nic_id": "30790131-39f1-dd1c-c457-3e8ed77e74f6",
82
+ "nic_name": "eth0",
83
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5"
84
+ },
85
+ {
86
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
87
+ "data_center_version": "9",
88
+ "firewall": {
89
+ "active": false,
90
+ "firewall_id": "3ccc6dd6-ddac-42e7-fb00-13f1853ee466",
91
+ "nic_id": "7c2cec85-435e-ddee-9a1c-ff88659ff9be",
92
+ "provisioning_state": "AVAILABLE"
93
+ },
94
+ "internet_access": false,
95
+ "ips": "10.7.232.11",
96
+ "lan_id": "1",
97
+ "mac_address": "02:01:8c:9c:50:3f",
98
+ "nic_id": "7c2cec85-435e-ddee-9a1c-ff88659ff9be",
99
+ "nic_name": "eth1",
100
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5"
101
+ }
102
+ ],
103
+ "os_type": "UNKNOWN",
104
+ "provisioning_state": "AVAILABLE",
105
+ "ram": "256",
106
+ "rom_drives": {
107
+ "image_id": "9de62e6e-ff1c-11e0-a1a7-0025901dfe2a",
108
+ "image_name": "grml64_2011.05.iso"
109
+ },
110
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5",
111
+ "server_name": "Test Server",
112
+ "virtual_machine_state": "RUNNING"
113
+ }
114
+ ],
115
+ "storages": [
116
+ {
117
+ "creation_time": "2012-03-03T23:28:44+01:00",
118
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
119
+ "data_center_version": "9",
120
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
121
+ "os_type": "UNKNOWN",
122
+ "provisioning_state": "AVAILABLE",
123
+ "server_ids": "51d54771-7566-4d9d-a560-1f2a3b61a4d5",
124
+ "size": "1",
125
+ "storage_id": "68f1badb-edbf-bb49-00cd-b5481ac91f7f",
126
+ "storage_name": "Empty"
127
+ },
128
+ {
129
+ "creation_time": "2012-03-03T23:28:44+01:00",
130
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
131
+ "data_center_version": "9",
132
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
133
+ "mount_image": {
134
+ "image_id": "d1d8747f-fa56-11e0-a1a7-0025901dfe2a",
135
+ "image_name": "profitbricks-debian-squeeze-EN-6.0.1a-amd64.img"
136
+ },
137
+ "os_type": "UNKNOWN",
138
+ "provisioning_state": "AVAILABLE",
139
+ "server_ids": "7e132ddb-b2c8-a109-7f99-7b4a32955006",
140
+ "size": "5",
141
+ "storage_id": "b6fdfa5b-fadf-5621-1be3-0882822abb88",
142
+ "storage_name": "Debian"
143
+ }
144
+ ]
145
+ }
146
+ }
147
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getDataCenterResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><dataCenterName>Test2</dataCenterName><servers><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><serverId>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverId><serverName>Test Server 2</serverName><cores>1</cores><ram>256</ram><internetAccess>false</internetAccess><ips>10.7.232.12</ips><connectedStorages><busType>VIRTIO</busType><deviceNumber>1</deviceNumber><size>5</size><storageId>b6fdfa5b-fadf-5621-1be3-0882822abb88</storageId><storageName>Debian</storageName></connectedStorages><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>8c5758c1-29b7-8a23-ffc8-4c54dac405c2</nicId><nicName>eth0</nicName><lanId>1</lanId><internetAccess>false</internetAccess><serverId>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverId><ips>10.7.232.12</ips><macAddress>02:01:eb:58:b1:63</macAddress><firewall><active>false</active><firewallId>374da20a-e7a4-151a-0be8-04c5b82409a0</firewallId><nicId>8c5758c1-29b7-8a23-ffc8-4c54dac405c2</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><provisioningState>AVAILABLE</provisioningState><virtualMachineState>RUNNING</virtualMachineState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>OTHER</osType></servers><servers><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><serverName>Test Server</serverName><cores>1</cores><ram>256</ram><internetAccess>true</internetAccess><ips>10.7.232.11</ips><ips>46.16.73.186</ips><connectedStorages><busType>VIRTIO</busType><deviceNumber>1</deviceNumber><size>1</size><storageId>68f1badb-edbf-bb49-00cd-b5481ac91f7f</storageId><storageName>Empty</storageName></connectedStorages><romDrives><imageId>9de62e6e-ff1c-11e0-a1a7-0025901dfe2a</imageId><imageName>grml64_2011.05.iso</imageName></romDrives><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>30790131-39f1-dd1c-c457-3e8ed77e74f6</nicId><nicName>eth0</nicName><lanId>2</lanId><internetAccess>true</internetAccess><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><ips>46.16.73.186</ips><macAddress>02:01:17:75:f9:cb</macAddress><firewall><active>false</active><firewallId>dac45569-b53a-c270-20c8-aa69aa071d28</firewallId><nicId>30790131-39f1-dd1c-c457-3e8ed77e74f6</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>7c2cec85-435e-ddee-9a1c-ff88659ff9be</nicId><nicName>eth1</nicName><lanId>1</lanId><internetAccess>false</internetAccess><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><ips>10.7.232.11</ips><macAddress>02:01:8c:9c:50:3f</macAddress><firewall><active>false</active><firewallId>3ccc6dd6-ddac-42e7-fb00-13f1853ee466</firewallId><nicId>7c2cec85-435e-ddee-9a1c-ff88659ff9be</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><provisioningState>AVAILABLE</provisioningState><virtualMachineState>RUNNING</virtualMachineState><creationTime>2012-03-02T15:40:24.093+01:00</creationTime><lastModificationTime>2012-03-02T15:57:31.190+01:00</lastModificationTime><osType>UNKNOWN</osType></servers><storages><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><storageId>68f1badb-edbf-bb49-00cd-b5481ac91f7f</storageId><size>1</size><storageName>Empty</storageName><serverIds>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverIds><provisioningState>AVAILABLE</provisioningState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>UNKNOWN</osType></storages><storages><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><storageId>b6fdfa5b-fadf-5621-1be3-0882822abb88</storageId><size>5</size><storageName>Debian</storageName><mountImage><imageId>d1d8747f-fa56-11e0-a1a7-0025901dfe2a</imageId><imageName>profitbricks-debian-squeeze-EN-6.0.1a-amd64.img</imageName></mountImage><serverIds>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverIds><provisioningState>AVAILABLE</provisioningState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>UNKNOWN</osType></storages><provisioningState>INPROCESS</provisioningState></return></ns2:getDataCenterResponse></S:Body></S:Envelope>
@@ -0,0 +1,147 @@
1
+ {
2
+ "get_data_center_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
6
+ "data_center_name": "Test",
7
+ "data_center_version": "9",
8
+ "provisioning_state": "AVAILABLE",
9
+ "servers": [
10
+ {
11
+ "connected_storages": {
12
+ "bus_type": "VIRTIO",
13
+ "device_number": "1",
14
+ "size": "5",
15
+ "storage_id": "b6fdfa5b-fadf-5621-1be3-0882822abb88",
16
+ "storage_name": "Debian"
17
+ },
18
+ "cores": "1",
19
+ "creation_time": "2012-03-03T23:28:44+01:00",
20
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
21
+ "data_center_version": "9",
22
+ "internet_access": false,
23
+ "ips": "10.7.232.12",
24
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
25
+ "nics": {
26
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
27
+ "data_center_version": "9",
28
+ "firewall": {
29
+ "active": false,
30
+ "firewall_id": "374da20a-e7a4-151a-0be8-04c5b82409a0",
31
+ "nic_id": "8c5758c1-29b7-8a23-ffc8-4c54dac405c2",
32
+ "provisioning_state": "AVAILABLE"
33
+ },
34
+ "internet_access": false,
35
+ "ips": "10.7.232.12",
36
+ "lan_id": "1",
37
+ "mac_address": "02:01:eb:58:b1:63",
38
+ "nic_id": "8c5758c1-29b7-8a23-ffc8-4c54dac405c2",
39
+ "nic_name": "eth0",
40
+ "server_id": "7e132ddb-b2c8-a109-7f99-7b4a32955006"
41
+ },
42
+ "os_type": "OTHER",
43
+ "provisioning_state": "AVAILABLE",
44
+ "ram": "256",
45
+ "server_id": "7e132ddb-b2c8-a109-7f99-7b4a32955006",
46
+ "server_name": "Test Server 2",
47
+ "virtual_machine_state": "RUNNING"
48
+ },
49
+ {
50
+ "connected_storages": {
51
+ "bus_type": "VIRTIO",
52
+ "device_number": "1",
53
+ "size": "1",
54
+ "storage_id": "68f1badb-edbf-bb49-00cd-b5481ac91f7f",
55
+ "storage_name": "Empty"
56
+ },
57
+ "cores": "1",
58
+ "creation_time": "2012-03-02T15:40:24+01:00",
59
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
60
+ "data_center_version": "9",
61
+ "internet_access": true,
62
+ "ips": [
63
+ "10.7.232.11",
64
+ "46.16.73.186"
65
+ ],
66
+ "last_modification_time": "2012-03-02T15:57:31+01:00",
67
+ "nics": [
68
+ {
69
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
70
+ "data_center_version": "9",
71
+ "firewall": {
72
+ "active": false,
73
+ "firewall_id": "dac45569-b53a-c270-20c8-aa69aa071d28",
74
+ "nic_id": "30790131-39f1-dd1c-c457-3e8ed77e74f6",
75
+ "provisioning_state": "AVAILABLE"
76
+ },
77
+ "internet_access": true,
78
+ "ips": "46.16.73.186",
79
+ "lan_id": "2",
80
+ "mac_address": "02:01:17:75:f9:cb",
81
+ "nic_id": "30790131-39f1-dd1c-c457-3e8ed77e74f6",
82
+ "nic_name": "eth0",
83
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5"
84
+ },
85
+ {
86
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
87
+ "data_center_version": "9",
88
+ "firewall": {
89
+ "active": false,
90
+ "firewall_id": "3ccc6dd6-ddac-42e7-fb00-13f1853ee466",
91
+ "nic_id": "7c2cec85-435e-ddee-9a1c-ff88659ff9be",
92
+ "provisioning_state": "AVAILABLE"
93
+ },
94
+ "internet_access": false,
95
+ "ips": "10.7.232.11",
96
+ "lan_id": "1",
97
+ "mac_address": "02:01:8c:9c:50:3f",
98
+ "nic_id": "7c2cec85-435e-ddee-9a1c-ff88659ff9be",
99
+ "nic_name": "eth1",
100
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5"
101
+ }
102
+ ],
103
+ "os_type": "UNKNOWN",
104
+ "provisioning_state": "AVAILABLE",
105
+ "ram": "256",
106
+ "rom_drives": {
107
+ "image_id": "9de62e6e-ff1c-11e0-a1a7-0025901dfe2a",
108
+ "image_name": "grml64_2011.05.iso"
109
+ },
110
+ "server_id": "51d54771-7566-4d9d-a560-1f2a3b61a4d5",
111
+ "server_name": "Test Server",
112
+ "virtual_machine_state": "RUNNING"
113
+ }
114
+ ],
115
+ "storages": [
116
+ {
117
+ "creation_time": "2012-03-03T23:28:44+01:00",
118
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
119
+ "data_center_version": "9",
120
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
121
+ "os_type": "UNKNOWN",
122
+ "provisioning_state": "AVAILABLE",
123
+ "server_ids": "51d54771-7566-4d9d-a560-1f2a3b61a4d5",
124
+ "size": "1",
125
+ "storage_id": "68f1badb-edbf-bb49-00cd-b5481ac91f7f",
126
+ "storage_name": "Empty"
127
+ },
128
+ {
129
+ "creation_time": "2012-03-03T23:28:44+01:00",
130
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
131
+ "data_center_version": "9",
132
+ "last_modification_time": "2012-03-03T23:28:44+01:00",
133
+ "mount_image": {
134
+ "image_id": "d1d8747f-fa56-11e0-a1a7-0025901dfe2a",
135
+ "image_name": "profitbricks-debian-squeeze-EN-6.0.1a-amd64.img"
136
+ },
137
+ "os_type": "UNKNOWN",
138
+ "provisioning_state": "AVAILABLE",
139
+ "server_ids": "7e132ddb-b2c8-a109-7f99-7b4a32955006",
140
+ "size": "5",
141
+ "storage_id": "b6fdfa5b-fadf-5621-1be3-0882822abb88",
142
+ "storage_name": "Debian"
143
+ }
144
+ ]
145
+ }
146
+ }
147
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getDataCenterResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><dataCenterName>Test</dataCenterName><servers><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><serverId>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverId><serverName>Test Server 2</serverName><cores>1</cores><ram>256</ram><internetAccess>false</internetAccess><ips>10.7.232.12</ips><connectedStorages><busType>VIRTIO</busType><deviceNumber>1</deviceNumber><size>5</size><storageId>b6fdfa5b-fadf-5621-1be3-0882822abb88</storageId><storageName>Debian</storageName></connectedStorages><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>8c5758c1-29b7-8a23-ffc8-4c54dac405c2</nicId><nicName>eth0</nicName><lanId>1</lanId><internetAccess>false</internetAccess><serverId>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverId><ips>10.7.232.12</ips><macAddress>02:01:eb:58:b1:63</macAddress><firewall><active>false</active><firewallId>374da20a-e7a4-151a-0be8-04c5b82409a0</firewallId><nicId>8c5758c1-29b7-8a23-ffc8-4c54dac405c2</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><provisioningState>AVAILABLE</provisioningState><virtualMachineState>RUNNING</virtualMachineState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>OTHER</osType></servers><servers><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><serverName>Test Server</serverName><cores>1</cores><ram>256</ram><internetAccess>true</internetAccess><ips>10.7.232.11</ips><ips>46.16.73.186</ips><connectedStorages><busType>VIRTIO</busType><deviceNumber>1</deviceNumber><size>1</size><storageId>68f1badb-edbf-bb49-00cd-b5481ac91f7f</storageId><storageName>Empty</storageName></connectedStorages><romDrives><imageId>9de62e6e-ff1c-11e0-a1a7-0025901dfe2a</imageId><imageName>grml64_2011.05.iso</imageName></romDrives><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>30790131-39f1-dd1c-c457-3e8ed77e74f6</nicId><nicName>eth0</nicName><lanId>2</lanId><internetAccess>true</internetAccess><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><ips>46.16.73.186</ips><macAddress>02:01:17:75:f9:cb</macAddress><firewall><active>false</active><firewallId>dac45569-b53a-c270-20c8-aa69aa071d28</firewallId><nicId>30790131-39f1-dd1c-c457-3e8ed77e74f6</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><nics><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><nicId>7c2cec85-435e-ddee-9a1c-ff88659ff9be</nicId><nicName>eth1</nicName><lanId>1</lanId><internetAccess>false</internetAccess><serverId>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverId><ips>10.7.232.11</ips><macAddress>02:01:8c:9c:50:3f</macAddress><firewall><active>false</active><firewallId>3ccc6dd6-ddac-42e7-fb00-13f1853ee466</firewallId><nicId>7c2cec85-435e-ddee-9a1c-ff88659ff9be</nicId><provisioningState>AVAILABLE</provisioningState></firewall></nics><provisioningState>AVAILABLE</provisioningState><virtualMachineState>RUNNING</virtualMachineState><creationTime>2012-03-02T15:40:24.093+01:00</creationTime><lastModificationTime>2012-03-02T15:57:31.190+01:00</lastModificationTime><osType>UNKNOWN</osType></servers><storages><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><storageId>68f1badb-edbf-bb49-00cd-b5481ac91f7f</storageId><size>1</size><storageName>Empty</storageName><serverIds>51d54771-7566-4d9d-a560-1f2a3b61a4d5</serverIds><provisioningState>AVAILABLE</provisioningState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>UNKNOWN</osType></storages><storages><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>9</dataCenterVersion><storageId>b6fdfa5b-fadf-5621-1be3-0882822abb88</storageId><size>5</size><storageName>Debian</storageName><mountImage><imageId>d1d8747f-fa56-11e0-a1a7-0025901dfe2a</imageId><imageName>profitbricks-debian-squeeze-EN-6.0.1a-amd64.img</imageName></mountImage><serverIds>7e132ddb-b2c8-a109-7f99-7b4a32955006</serverIds><provisioningState>AVAILABLE</provisioningState><creationTime>2012-03-03T23:28:44.152+01:00</creationTime><lastModificationTime>2012-03-03T23:28:44.152+01:00</lastModificationTime><osType>UNKNOWN</osType></storages><provisioningState>INPROCESS</provisioningState></return></ns2:getDataCenterResponse></S:Body></S:Envelope>
@@ -0,0 +1 @@
1
+ {"get_data_center_state_response":{"return":"INPROCESS","@xmlns:ns2":"http://ws.api.profitbricks.com/"}}
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getDataCenterStateResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return>INPROCESS</return></ns2:getDataCenterStateResponse></S:Body></S:Envelope>
@@ -0,0 +1 @@
1
+ {"get_data_center_state_response":{"return":"AVAILABLE","@xmlns:ns2":"http://ws.api.profitbricks.com/"}}
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getDataCenterStateResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return>AVAILABLE</return></ns2:getDataCenterStateResponse></S:Body></S:Envelope>
@@ -0,0 +1,15 @@
1
+ {
2
+ "get_image_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "cpu_hotpluggable": false,
6
+ "image_id": "5f58656e-66c3-11e1-8c6f-0025901dfe2a",
7
+ "image_name": "Windows8-ConsumerPreview-64bit-English.iso",
8
+ "image_size": "6",
9
+ "image_type": "CDROM",
10
+ "memory_hotpluggable": false,
11
+ "os_type": "UNKNOWN",
12
+ "writeable": true
13
+ }
14
+ }
15
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getImageResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><cpuHotpluggable>false</cpuHotpluggable><imageId>5f58656e-66c3-11e1-8c6f-0025901dfe2a</imageId><imageName>Windows8-ConsumerPreview-64bit-English.iso</imageName><imageSize>6</imageSize><imageType>CDROM</imageType><memoryHotpluggable>false</memoryHotpluggable><osType>UNKNOWN</osType><writeable>true</writeable></return></ns2:getImageResponse></S:Body></S:Envelope>
@@ -0,0 +1,16 @@
1
+ {
2
+ "get_nic_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
6
+ "data_center_version": "53",
7
+ "internet_access": false,
8
+ "ips": "192.168.0.11",
9
+ "lan_id": "1",
10
+ "mac_address": null,
11
+ "nic_id": "cba8af39-b5de-477b-9795-2f02ea9cf04f",
12
+ "nic_name": "Internal",
13
+ "server_id": "4cb6550f-3777-4818-8f4c-51233162a980"
14
+ }
15
+ }
16
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getNicResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>53</dataCenterVersion><nicId>cba8af39-b5de-477b-9795-2f02ea9cf04f</nicId><nicName>Internal</nicName><lanId>1</lanId><internetAccess>false</internetAccess><serverId>4cb6550f-3777-4818-8f4c-51233162a980</serverId><ips>192.168.0.11</ips><macAddress></macAddress></return></ns2:getNicResponse></S:Body></S:Envelope>
@@ -0,0 +1,19 @@
1
+ {
2
+ "get_nic_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
6
+ "data_center_version": "58",
7
+ "internet_access": true,
8
+ "ips": [
9
+ "192.168.0.11",
10
+ "46.16.74.13"
11
+ ],
12
+ "lan_id": "1",
13
+ "mac_address": "02:01:d3:b7:e9:43",
14
+ "nic_id": "cba8af39-b5de-477b-9795-2f02ea9cf04f",
15
+ "nic_name": "External",
16
+ "server_id": "4cb6550f-3777-4818-8f4c-51233162a980"
17
+ }
18
+ }
19
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getNicResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>58</dataCenterVersion><nicId>cba8af39-b5de-477b-9795-2f02ea9cf04f</nicId><nicName>External</nicName><lanId>1</lanId><internetAccess>true</internetAccess><serverId>4cb6550f-3777-4818-8f4c-51233162a980</serverId><ips>192.168.0.11</ips><ips>46.16.74.13</ips><macAddress>02:01:d3:b7:e9:43</macAddress></return></ns2:getNicResponse></S:Body></S:Envelope>
@@ -0,0 +1,17 @@
1
+ {
2
+ "get_server_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "cores": "1",
6
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
7
+ "data_center_version": "13",
8
+ "internet_access": false,
9
+ "os_type": "UNKNOWN",
10
+ "provisioning_state": "INACTIVE",
11
+ "ram": "256",
12
+ "server_id": "b7a5f3d1-324a-4490-aa8e-56cdec436e3f",
13
+ "server_name": "Test Server",
14
+ "virtual_machine_state": "NOSTATE"
15
+ }
16
+ }
17
+ }
@@ -0,0 +1 @@
1
+ <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getServerResponse xmlns:ns2="http://ws.api.profitbricks.com/"><return><dataCenterId>b3eebede-5c78-417c-b1bc-ff5de01a0602</dataCenterId><dataCenterVersion>13</dataCenterVersion><serverId>b7a5f3d1-324a-4490-aa8e-56cdec436e3f</serverId><serverName>Test Server</serverName><cores>1</cores><ram>256</ram><internetAccess>false</internetAccess><provisioningState>INACTIVE</provisioningState><virtualMachineState>NOSTATE</virtualMachineState><osType>UNKNOWN</osType></return></ns2:getServerResponse></S:Body></S:Envelope>
@@ -0,0 +1,26 @@
1
+ {
2
+ "get_server_response": {
3
+ "@xmlns:ns2": "http://ws.api.profitbricks.com/",
4
+ "return": {
5
+ "connected_storages": {
6
+ "bus_type": "VIRTIO",
7
+ "device_number": "900",
8
+ "size": "5",
9
+ "storage_id": "f55952bc-da27-4e29-af89-ed212ea28e11",
10
+ "storage_name": "Test Storage"
11
+ },
12
+ "cores": "1",
13
+ "creation_time": "2012-03-04T23:04:26+01:00",
14
+ "data_center_id": "b3eebede-5c78-417c-b1bc-ff5de01a0602",
15
+ "data_center_version": "35",
16
+ "internet_access": false,
17
+ "last_modification_time": "2012-03-05T11:25:11+01:00",
18
+ "os_type": "UNKNOWN",
19
+ "provisioning_state": "AVAILABLE",
20
+ "ram": "256",
21
+ "server_id": "4cb6550f-3777-4818-8f4c-51233162a980",
22
+ "server_name": "Power of two",
23
+ "virtual_machine_state": "RUNNING"
24
+ }
25
+ }
26
+ }