yao 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/yao/resources/action.rb +1 -1
- data/lib/yao/resources/keypair.rb +3 -1
- data/lib/yao/resources/server.rb +7 -0
- data/lib/yao/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a43847afb896259ec838b7c1868c57657092a245
|
4
|
+
data.tar.gz: 60410d2891988b2acb4894e8cbffd09b81e007f5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e2a41e0532be69ffeef29dc41a86106217dc2b364e66bc3de22cc84c888ec01386f70b916f37b93d0d1f664b7a1fe7bef188e08c3acf82a41697ea8c8c9dfc68
|
7
|
+
data.tar.gz: 1ccf43b776c2319282165759adcb01c1445f459dc50ff5f4204265d1b919757e2ea887b82ed870b493742323f2c7310098c7873832617fb171119bc242b3c1b7
|
data/CHANGELOG.md
ADDED
data/lib/yao/resources/action.rb
CHANGED
@@ -7,7 +7,9 @@ module Yao::Resources
|
|
7
7
|
self.resources_name = "os-keypairs"
|
8
8
|
|
9
9
|
def self.list(query={})
|
10
|
-
return_resources(
|
10
|
+
return_resources(
|
11
|
+
resources_from_json(GET(resources_name, query).body).map{|r| resource_params(r)}
|
12
|
+
)
|
11
13
|
end
|
12
14
|
end
|
13
15
|
end
|
data/lib/yao/resources/server.rb
CHANGED
@@ -21,6 +21,9 @@ module Yao::Resources
|
|
21
21
|
self.service = "compute"
|
22
22
|
self.resource_name = "server"
|
23
23
|
self.resources_name = "servers"
|
24
|
+
def self.start(id)
|
25
|
+
action(id, "os-start" => nil)
|
26
|
+
end
|
24
27
|
|
25
28
|
def self.shutoff(id)
|
26
29
|
action(id, "os-stop" => nil)
|
@@ -34,6 +37,10 @@ module Yao::Resources
|
|
34
37
|
action(id,"resize" => { "flavorRef" => flavor_id })
|
35
38
|
end
|
36
39
|
|
40
|
+
class << self
|
41
|
+
alias :stop :shutoff
|
42
|
+
end
|
43
|
+
|
37
44
|
extend MetadataAvailable
|
38
45
|
extend Action
|
39
46
|
end
|
data/lib/yao/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yao
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Uchio, KONDO
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-11-
|
11
|
+
date: 2015-11-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|
@@ -159,6 +159,7 @@ extra_rdoc_files: []
|
|
159
159
|
files:
|
160
160
|
- ".gitignore"
|
161
161
|
- ".travis.yml"
|
162
|
+
- CHANGELOG.md
|
162
163
|
- CODE_OF_CONDUCT.md
|
163
164
|
- Gemfile
|
164
165
|
- LICENSE.txt
|