deis-workflow 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/deis-workflow.rb +19 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dc6bfa17e2604be35121f34709bad97780680948
|
4
|
+
data.tar.gz: 4b4f48725af9f6e678003e1d4624f92817c1483c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28b63a379bcbc2a9c3c78f926ed2abc6f67a14cdbb86e0d56305c866ccb4ad121e46ec11cbed76bce4f5ecf7599a2c74ef938c78b51d46354afea44d96bbd1ec
|
7
|
+
data.tar.gz: 61715038a69a3fed8d2ae9c16a5098ad6efade4f31916df3dade872bcb8a4566ec18bfc8b0a236aa099d52e3301c92342f247c29465e79f14cbd53e2818e199d
|
data/lib/deis-workflow.rb
CHANGED
@@ -67,6 +67,10 @@ module DeisWorkflow
|
|
67
67
|
get("#{app_path(app_name)}/logs/").parsed_response
|
68
68
|
end
|
69
69
|
|
70
|
+
def app_releases(app_name)
|
71
|
+
get("#{app_path(app_name)}/releases").parsed_response
|
72
|
+
end
|
73
|
+
|
70
74
|
### App pod related methods
|
71
75
|
|
72
76
|
def app_scale(app_name, pod_type, desired_pod_count)
|
@@ -113,6 +117,21 @@ module DeisWorkflow
|
|
113
117
|
}).success?
|
114
118
|
end
|
115
119
|
|
120
|
+
def app_limit_set(app_name, limit_type, pod_type, limit)
|
121
|
+
return false unless %w(memory cpu).include?(limit_type)
|
122
|
+
post("#{app_path(app_name)}/config/", {
|
123
|
+
limit_type => { pod_type => limit }
|
124
|
+
}).success?
|
125
|
+
end
|
126
|
+
|
127
|
+
def app_limit_unset(app_name, limit_type, pod_type)
|
128
|
+
return false unless %w(memory cpu).include?(limit_type)
|
129
|
+
post("#{app_path(app_name)}/config/", {
|
130
|
+
limit_type => { pod_type => nil }
|
131
|
+
}).success?
|
132
|
+
end
|
133
|
+
|
134
|
+
|
116
135
|
private
|
117
136
|
|
118
137
|
def app_path(app_name)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: deis-workflow
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Thomas Davies
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-11-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|