digital_ocean 0.0.1alpha1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (67) hide show
  1. data/.gitignore +18 -0
  2. data/.rspec +2 -0
  3. data/.travis.yml +9 -0
  4. data/Gemfile +4 -0
  5. data/Guardfile +11 -0
  6. data/LICENSE.txt +22 -0
  7. data/README.md +32 -0
  8. data/Rakefile +17 -0
  9. data/digital_ocean.gemspec +38 -0
  10. data/lib/digital_ocean/api.rb +46 -0
  11. data/lib/digital_ocean/authentication_middleware.rb +29 -0
  12. data/lib/digital_ocean/resource/base.rb +22 -0
  13. data/lib/digital_ocean/resource/droplet.rb +84 -0
  14. data/lib/digital_ocean/resource/image.rb +17 -0
  15. data/lib/digital_ocean/resource/region.rb +9 -0
  16. data/lib/digital_ocean/resource/size.rb +9 -0
  17. data/lib/digital_ocean/resource/ssh_key.rb +27 -0
  18. data/lib/digital_ocean/resource.rb +12 -0
  19. data/lib/digital_ocean/version.rb +3 -0
  20. data/lib/digital_ocean.rb +10 -0
  21. data/spec/api_spec.rb +421 -0
  22. data/spec/digital_ocean_spec.rb +7 -0
  23. data/spec/spec_helper.rb +21 -0
  24. data/spec/support/vcr.rb +21 -0
  25. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_create/should_be_successful.yml +48 -0
  26. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_delete/should_be_successful.yml +48 -0
  27. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_disable_backups/should_be_successful.yml +48 -0
  28. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_enable_backups/should_be_successful.yml +48 -0
  29. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_list/should_be_successful.yml +48 -0
  30. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_list/should_return_a_list_of_all_droplets.yml +48 -0
  31. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_power_cycle/should_be_successful.yml +48 -0
  32. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_power_off/should_be_successful.yml +48 -0
  33. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_power_on/should_be_successful.yml +48 -0
  34. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_reboot/should_be_successful.yml +48 -0
  35. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_rebuild/should_be_successful.yml +48 -0
  36. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_reset_root_password/should_be_successful.yml +49 -0
  37. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_resize/should_be_successful.yml +48 -0
  38. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_restore/should_be_successful.yml +48 -0
  39. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_show/should_be_successful.yml +48 -0
  40. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_shutdown/should_be_successful.yml +48 -0
  41. data/spec/vcr/cassettes/DigitalOcean_API/_droplets/_snapshot/should_be_successful.yml +48 -0
  42. data/spec/vcr/cassettes/DigitalOcean_API/_images/_delete/invalid/should_not_be_successful.yml +48 -0
  43. data/spec/vcr/cassettes/DigitalOcean_API/_images/_delete/valid/should_be_successful.yml +49 -0
  44. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/with_filter_global/should_be_successful.yml +69 -0
  45. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/with_filter_global/should_return_global_images.yml +69 -0
  46. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/with_filter_my_images/should_be_successful.yml +48 -0
  47. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/with_filter_my_images/should_return_my_images.yml +48 -0
  48. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/without_filter/should_be_successful.yml +70 -0
  49. data/spec/vcr/cassettes/DigitalOcean_API/_images/_list/without_filter/should_return_a_list_of_all_images.yml +70 -0
  50. data/spec/vcr/cassettes/DigitalOcean_API/_images/_show/invalid/should_not_be_successful.yml +48 -0
  51. data/spec/vcr/cassettes/DigitalOcean_API/_images/_show/valid/should_be_successful.yml +48 -0
  52. data/spec/vcr/cassettes/DigitalOcean_API/_images/_show/valid/should_return_the_image.yml +48 -0
  53. data/spec/vcr/cassettes/DigitalOcean_API/_regions/_list/should_be_successful.yml +49 -0
  54. data/spec/vcr/cassettes/DigitalOcean_API/_regions/_list/should_return_a_list_of_all_available_regions.yml +49 -0
  55. data/spec/vcr/cassettes/DigitalOcean_API/_regions/_list/should_return_a_list_of_all_regions.yml +49 -0
  56. data/spec/vcr/cassettes/DigitalOcean_API/_sizes/_list/should_be_successful.yml +48 -0
  57. data/spec/vcr/cassettes/DigitalOcean_API/_sizes/_list/should_return_a_list_of_all_droplet_sizes.yml +48 -0
  58. data/spec/vcr/cassettes/DigitalOcean_API/_sizes/_list/should_return_the_correct_ID_for_the_96GB_size.yml +48 -0
  59. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_add/should_be_successful.yml +48 -0
  60. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_delete/should_be_successful.yml +48 -0
  61. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_list/should_be_successful.yml +48 -0
  62. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_list/should_return_a_list_of_all_SSH_keys.yml +48 -0
  63. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_show/invalid/should_not_be_successful.yml +48 -0
  64. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_show/valid/should_be_successful.yml +50 -0
  65. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_show/valid/should_return_a_list_of_all_SSH_keys.yml +50 -0
  66. data/spec/vcr/cassettes/DigitalOcean_API/_ssh_keys/_show/valid/should_return_the_public_keykey.yml +50 -0
  67. metadata +353 -0
@@ -0,0 +1,49 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images/57089/destroy?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:16:24 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - ab006eb33322bb957b0039bd9d651c45
39
+ x-runtime:
40
+ - '0.474210'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"ERROR","error_message":{"action":["Invalid Action - The
46
+ action you specified cannot be found"]}}'
47
+ http_version:
48
+ recorded_at: Wed, 23 Jan 2013 21:16:24 GMT
49
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,69 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY&filter=global
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:43 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - 51f0a89650ea6729675a0762c5f74e58
39
+ x-runtime:
40
+ - '0.192580'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":1601,"name":"CentOS 5.8 x64","distribution":"CentOS"},{"id":1602,"name":"CentOS
46
+ 5.8 x32","distribution":"CentOS"},{"id":1605,"name":"CentOS 6.0 x32","distribution":"CentOS"},{"id":1606,"name":"Fedora
47
+ 15 x64","distribution":"Fedora"},{"id":1607,"name":"Gentoo x64","distribution":"Gentoo"},{"id":1609,"name":"Ubuntu
48
+ 11.10 x32 Server","distribution":"Ubuntu"},{"id":1611,"name":"CentOS 6.2 x64","distribution":"CentOS"},{"id":1615,"name":"Fedora
49
+ 16 x64 Server","distribution":"Fedora"},{"id":1618,"name":"Fedora 16 x64 Desktop","distribution":"Fedora"},{"id":2676,"name":"Ubuntu
50
+ 12.04 x64 Server","distribution":"Ubuntu"},{"id":4870,"name":"Rails 3.2.2
51
+ - Nginx MySQL Passenger","distribution":"Ubuntu"},{"id":12573,"name":"Debian
52
+ 6.0 x64","distribution":"Debian"},{"id":12574,"name":"CentOS 6.3 x64","distribution":"CentOS"},{"id":12575,"name":"Debian
53
+ 6.0 x32","distribution":"Debian"},{"id":12578,"name":"CentOS 6.3 x32","distribution":"CentOS"},{"id":13632,"name":"Open
54
+ Suse 12.1 x32","distribution":"openSUSE"},{"id":13863,"name":"Open Suse 12.2
55
+ X64","distribution":"openSUSE"},{"id":14097,"name":"Ubuntu 10.04 x64 Server","distribution":"Ubuntu"},{"id":14098,"name":"Ubuntu
56
+ 10.04 x32 Server","distribution":"Ubuntu"},{"id":14218,"name":"Ubuntu 12.04
57
+ x64 Desktop","distribution":"Ubuntu"},{"id":23593,"name":"Arch Linux 2012-09
58
+ x64","distribution":"Arch Linux"},{"id":25306,"name":"Ubuntu 12.10 x32 Server","distribution":"Ubuntu"},{"id":25485,"name":"Ubuntu
59
+ 12.10 x32 Desktop","distribution":"Ubuntu"},{"id":25489,"name":"Ubuntu 12.10
60
+ x64 Server","distribution":"Ubuntu"},{"id":25493,"name":"Ubuntu 12.10 x64
61
+ Desktop","distribution":"Ubuntu"},{"id":32387,"name":"Fedora 17 x32 Server","distribution":"Fedora"},{"id":32399,"name":"Fedora
62
+ 17 x32 Desktop","distribution":"Fedora"},{"id":32419,"name":"Fedora 17 x64
63
+ Desktop","distribution":"Fedora"},{"id":32428,"name":"Fedora 17 x64 Server","distribution":"Fedora"},{"id":42735,"name":"Ubuntu
64
+ 12.04 x32 Server","distribution":"Ubuntu"},{"id":43458,"name":"Ubuntu 11.04x64
65
+ Server","distribution":"Ubuntu"},{"id":43462,"name":"Ubuntu 11.04x32 Desktop","distribution":"Ubuntu"},{"id":46964,"name":"LAMP
66
+ on Ubuntu 12.04","distribution":"Ubuntu"}]}'
67
+ http_version:
68
+ recorded_at: Wed, 23 Jan 2013 21:04:43 GMT
69
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,69 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY&filter=global
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:43 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - 4bd3556237c698c19ae6092e67bc7961
39
+ x-runtime:
40
+ - '0.181610'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":1601,"name":"CentOS 5.8 x64","distribution":"CentOS"},{"id":1602,"name":"CentOS
46
+ 5.8 x32","distribution":"CentOS"},{"id":1605,"name":"CentOS 6.0 x32","distribution":"CentOS"},{"id":1606,"name":"Fedora
47
+ 15 x64","distribution":"Fedora"},{"id":1607,"name":"Gentoo x64","distribution":"Gentoo"},{"id":1609,"name":"Ubuntu
48
+ 11.10 x32 Server","distribution":"Ubuntu"},{"id":1611,"name":"CentOS 6.2 x64","distribution":"CentOS"},{"id":1615,"name":"Fedora
49
+ 16 x64 Server","distribution":"Fedora"},{"id":1618,"name":"Fedora 16 x64 Desktop","distribution":"Fedora"},{"id":2676,"name":"Ubuntu
50
+ 12.04 x64 Server","distribution":"Ubuntu"},{"id":4870,"name":"Rails 3.2.2
51
+ - Nginx MySQL Passenger","distribution":"Ubuntu"},{"id":12573,"name":"Debian
52
+ 6.0 x64","distribution":"Debian"},{"id":12574,"name":"CentOS 6.3 x64","distribution":"CentOS"},{"id":12575,"name":"Debian
53
+ 6.0 x32","distribution":"Debian"},{"id":12578,"name":"CentOS 6.3 x32","distribution":"CentOS"},{"id":13632,"name":"Open
54
+ Suse 12.1 x32","distribution":"openSUSE"},{"id":13863,"name":"Open Suse 12.2
55
+ X64","distribution":"openSUSE"},{"id":14097,"name":"Ubuntu 10.04 x64 Server","distribution":"Ubuntu"},{"id":14098,"name":"Ubuntu
56
+ 10.04 x32 Server","distribution":"Ubuntu"},{"id":14218,"name":"Ubuntu 12.04
57
+ x64 Desktop","distribution":"Ubuntu"},{"id":23593,"name":"Arch Linux 2012-09
58
+ x64","distribution":"Arch Linux"},{"id":25306,"name":"Ubuntu 12.10 x32 Server","distribution":"Ubuntu"},{"id":25485,"name":"Ubuntu
59
+ 12.10 x32 Desktop","distribution":"Ubuntu"},{"id":25489,"name":"Ubuntu 12.10
60
+ x64 Server","distribution":"Ubuntu"},{"id":25493,"name":"Ubuntu 12.10 x64
61
+ Desktop","distribution":"Ubuntu"},{"id":32387,"name":"Fedora 17 x32 Server","distribution":"Fedora"},{"id":32399,"name":"Fedora
62
+ 17 x32 Desktop","distribution":"Fedora"},{"id":32419,"name":"Fedora 17 x64
63
+ Desktop","distribution":"Fedora"},{"id":32428,"name":"Fedora 17 x64 Server","distribution":"Fedora"},{"id":42735,"name":"Ubuntu
64
+ 12.04 x32 Server","distribution":"Ubuntu"},{"id":43458,"name":"Ubuntu 11.04x64
65
+ Server","distribution":"Ubuntu"},{"id":43462,"name":"Ubuntu 11.04x32 Desktop","distribution":"Ubuntu"},{"id":46964,"name":"LAMP
66
+ on Ubuntu 12.04","distribution":"Ubuntu"}]}'
67
+ http_version:
68
+ recorded_at: Wed, 23 Jan 2013 21:04:43 GMT
69
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY&filter=my_images
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:45 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - e68dfef4fee5aa18056cc754dced23db
39
+ x-runtime:
40
+ - '0.875055'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":57002,"name":"init","distribution":"Ubuntu"},{"id":57089,"name":"test1","distribution":"Ubuntu"}]}'
46
+ http_version:
47
+ recorded_at: Wed, 23 Jan 2013 21:04:45 GMT
48
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY&filter=my_images
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:46 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - cef3f095a7c92ba352c12492db25dbfd
39
+ x-runtime:
40
+ - '0.530997'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":57002,"name":"init","distribution":"Ubuntu"},{"id":57089,"name":"test1","distribution":"Ubuntu"}]}'
46
+ http_version:
47
+ recorded_at: Wed, 23 Jan 2013 21:04:46 GMT
48
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,70 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:41 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - 53469a4dafa7b91febb4567fba656990
39
+ x-runtime:
40
+ - '1.111869'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":57002,"name":"init","distribution":"Ubuntu"},{"id":57089,"name":"test1","distribution":"Ubuntu"},{"id":1601,"name":"CentOS
46
+ 5.8 x64","distribution":"CentOS"},{"id":1602,"name":"CentOS 5.8 x32","distribution":"CentOS"},{"id":1605,"name":"CentOS
47
+ 6.0 x32","distribution":"CentOS"},{"id":1606,"name":"Fedora 15 x64","distribution":"Fedora"},{"id":1607,"name":"Gentoo
48
+ x64","distribution":"Gentoo"},{"id":1609,"name":"Ubuntu 11.10 x32 Server","distribution":"Ubuntu"},{"id":1611,"name":"CentOS
49
+ 6.2 x64","distribution":"CentOS"},{"id":1615,"name":"Fedora 16 x64 Server","distribution":"Fedora"},{"id":1618,"name":"Fedora
50
+ 16 x64 Desktop","distribution":"Fedora"},{"id":2676,"name":"Ubuntu 12.04 x64
51
+ Server","distribution":"Ubuntu"},{"id":4870,"name":"Rails 3.2.2 - Nginx MySQL
52
+ Passenger","distribution":"Ubuntu"},{"id":12573,"name":"Debian 6.0 x64","distribution":"Debian"},{"id":12574,"name":"CentOS
53
+ 6.3 x64","distribution":"CentOS"},{"id":12575,"name":"Debian 6.0 x32","distribution":"Debian"},{"id":12578,"name":"CentOS
54
+ 6.3 x32","distribution":"CentOS"},{"id":13632,"name":"Open Suse 12.1 x32","distribution":"openSUSE"},{"id":13863,"name":"Open
55
+ Suse 12.2 X64","distribution":"openSUSE"},{"id":14097,"name":"Ubuntu 10.04
56
+ x64 Server","distribution":"Ubuntu"},{"id":14098,"name":"Ubuntu 10.04 x32
57
+ Server","distribution":"Ubuntu"},{"id":14218,"name":"Ubuntu 12.04 x64 Desktop","distribution":"Ubuntu"},{"id":23593,"name":"Arch
58
+ Linux 2012-09 x64","distribution":"Arch Linux"},{"id":25306,"name":"Ubuntu
59
+ 12.10 x32 Server","distribution":"Ubuntu"},{"id":25485,"name":"Ubuntu 12.10
60
+ x32 Desktop","distribution":"Ubuntu"},{"id":25489,"name":"Ubuntu 12.10 x64
61
+ Server","distribution":"Ubuntu"},{"id":25493,"name":"Ubuntu 12.10 x64 Desktop","distribution":"Ubuntu"},{"id":32387,"name":"Fedora
62
+ 17 x32 Server","distribution":"Fedora"},{"id":32399,"name":"Fedora 17 x32
63
+ Desktop","distribution":"Fedora"},{"id":32419,"name":"Fedora 17 x64 Desktop","distribution":"Fedora"},{"id":32428,"name":"Fedora
64
+ 17 x64 Server","distribution":"Fedora"},{"id":42735,"name":"Ubuntu 12.04 x32
65
+ Server","distribution":"Ubuntu"},{"id":43458,"name":"Ubuntu 11.04x64 Server","distribution":"Ubuntu"},{"id":43462,"name":"Ubuntu
66
+ 11.04x32 Desktop","distribution":"Ubuntu"},{"id":46964,"name":"LAMP on Ubuntu
67
+ 12.04","distribution":"Ubuntu"}]}'
68
+ http_version:
69
+ recorded_at: Wed, 23 Jan 2013 21:04:41 GMT
70
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,70 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:04:42 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - f6a0ae5392f0888e99809aa14dc63c18
39
+ x-runtime:
40
+ - '0.190669'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","images":[{"id":57002,"name":"init","distribution":"Ubuntu"},{"id":57089,"name":"test1","distribution":"Ubuntu"},{"id":1601,"name":"CentOS
46
+ 5.8 x64","distribution":"CentOS"},{"id":1602,"name":"CentOS 5.8 x32","distribution":"CentOS"},{"id":1605,"name":"CentOS
47
+ 6.0 x32","distribution":"CentOS"},{"id":1606,"name":"Fedora 15 x64","distribution":"Fedora"},{"id":1607,"name":"Gentoo
48
+ x64","distribution":"Gentoo"},{"id":1609,"name":"Ubuntu 11.10 x32 Server","distribution":"Ubuntu"},{"id":1611,"name":"CentOS
49
+ 6.2 x64","distribution":"CentOS"},{"id":1615,"name":"Fedora 16 x64 Server","distribution":"Fedora"},{"id":1618,"name":"Fedora
50
+ 16 x64 Desktop","distribution":"Fedora"},{"id":2676,"name":"Ubuntu 12.04 x64
51
+ Server","distribution":"Ubuntu"},{"id":4870,"name":"Rails 3.2.2 - Nginx MySQL
52
+ Passenger","distribution":"Ubuntu"},{"id":12573,"name":"Debian 6.0 x64","distribution":"Debian"},{"id":12574,"name":"CentOS
53
+ 6.3 x64","distribution":"CentOS"},{"id":12575,"name":"Debian 6.0 x32","distribution":"Debian"},{"id":12578,"name":"CentOS
54
+ 6.3 x32","distribution":"CentOS"},{"id":13632,"name":"Open Suse 12.1 x32","distribution":"openSUSE"},{"id":13863,"name":"Open
55
+ Suse 12.2 X64","distribution":"openSUSE"},{"id":14097,"name":"Ubuntu 10.04
56
+ x64 Server","distribution":"Ubuntu"},{"id":14098,"name":"Ubuntu 10.04 x32
57
+ Server","distribution":"Ubuntu"},{"id":14218,"name":"Ubuntu 12.04 x64 Desktop","distribution":"Ubuntu"},{"id":23593,"name":"Arch
58
+ Linux 2012-09 x64","distribution":"Arch Linux"},{"id":25306,"name":"Ubuntu
59
+ 12.10 x32 Server","distribution":"Ubuntu"},{"id":25485,"name":"Ubuntu 12.10
60
+ x32 Desktop","distribution":"Ubuntu"},{"id":25489,"name":"Ubuntu 12.10 x64
61
+ Server","distribution":"Ubuntu"},{"id":25493,"name":"Ubuntu 12.10 x64 Desktop","distribution":"Ubuntu"},{"id":32387,"name":"Fedora
62
+ 17 x32 Server","distribution":"Fedora"},{"id":32399,"name":"Fedora 17 x32
63
+ Desktop","distribution":"Fedora"},{"id":32419,"name":"Fedora 17 x64 Desktop","distribution":"Fedora"},{"id":32428,"name":"Fedora
64
+ 17 x64 Server","distribution":"Fedora"},{"id":42735,"name":"Ubuntu 12.04 x32
65
+ Server","distribution":"Ubuntu"},{"id":43458,"name":"Ubuntu 11.04x64 Server","distribution":"Ubuntu"},{"id":43462,"name":"Ubuntu
66
+ 11.04x32 Desktop","distribution":"Ubuntu"},{"id":46964,"name":"LAMP on Ubuntu
67
+ 12.04","distribution":"Ubuntu"}]}'
68
+ http_version:
69
+ recorded_at: Wed, 23 Jan 2013 21:04:42 GMT
70
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images/0?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:14:12 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - 90fb6236a7b535afc45624f84b24a121
39
+ x-runtime:
40
+ - '0.137921'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"ERROR","error_message":"No Image Found"}'
46
+ http_version:
47
+ recorded_at: Wed, 23 Jan 2013 21:14:12 GMT
48
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images/1601?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:14:10 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - e57d4c42c4abebebd92134d20c418b11
39
+ x-runtime:
40
+ - '0.586462'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","image":{"id":1601,"name":"CentOS 5.8 x64","distribution":"CentOS"}}'
46
+ http_version:
47
+ recorded_at: Wed, 23 Jan 2013 21:14:10 GMT
48
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/images/1601?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 21:14:11 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - 4e58e8ef32ccce0d5e247d696fed30d4
39
+ x-runtime:
40
+ - '0.261044'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","image":{"id":1601,"name":"CentOS 5.8 x64","distribution":"CentOS"}}'
46
+ http_version:
47
+ recorded_at: Wed, 23 Jan 2013 21:14:11 GMT
48
+ recorded_with: VCR 2.4.0
@@ -0,0 +1,49 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.digitalocean.com/regions?client_id=client_id_XXXXXXXXXXXXXXXXXXX&api_key=api_key_YYYYYYYYYYYYYYYYYYYYY
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers: {}
10
+ response:
11
+ status:
12
+ code: 200
13
+ message:
14
+ headers:
15
+ server:
16
+ - nginx
17
+ date:
18
+ - Wed, 23 Jan 2013 14:05:59 GMT
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ transfer-encoding:
22
+ - chunked
23
+ connection:
24
+ - close
25
+ status:
26
+ - '200'
27
+ x-powered-by:
28
+ - Phusion Passenger (mod_rails/mod_rack) 3.0.11
29
+ x-ua-compatible:
30
+ - IE=Edge,chrome=1
31
+ etag:
32
+ - XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
33
+ cache-control:
34
+ - max-age=0, private, must-revalidate
35
+ set-cookie:
36
+ - _digitalocean2_session=wtf
37
+ x-request-id:
38
+ - bd3acf9563ecea95e21b906d737425cc
39
+ x-runtime:
40
+ - '0.974501'
41
+ x-rack-cache:
42
+ - miss
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"status":"OK","regions":[{"id":1,"name":"New York 1"},{"id":2,"name":"Amsterdam
46
+ 1"}]}'
47
+ http_version:
48
+ recorded_at: Wed, 23 Jan 2013 14:05:59 GMT
49
+ recorded_with: VCR 2.4.0