deis_client 1.5.1 → 1.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/deis_client.rb +13 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 265cebd1f50d99c49a085790fd55a665564284e2
|
4
|
+
data.tar.gz: b199fa78e2e3392940a6d9aefd662deef9a9f517
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d709795f8857e42e7ab05440eab367f6236e3cf0feed788c4d292e2c5097478fdc95efcfb3369120b01db2b61f0d1b53059d05e95eb07071775a3c2eeb5c9ad3
|
7
|
+
data.tar.gz: d8e224c620c55c2965367a89945cc4ac036cca73e5e4eb95a252f70c3477799d80d293c45235d9689a89cc1e9516238a981c37c9ddef3e39624666c166594e7c
|
data/lib/deis_client.rb
CHANGED
@@ -69,6 +69,8 @@ module Deis
|
|
69
69
|
config: [:get, '/apps/:app/config/'],
|
70
70
|
set_config: [:post, '/apps/:app/config/'],
|
71
71
|
domains: [:get, '/apps/:app/domains/'],
|
72
|
+
add_domain: [:post, '/apps/:app/domains/'],
|
73
|
+
remove_domain: [:delete, '/apps/:app/domains/:domain'],
|
72
74
|
builds: [:get, '/apps/:app/builds/'],
|
73
75
|
create_build: [:post, '/apps/:app/builds/'],
|
74
76
|
releases: [:get, '/apps/:app/releases/'],
|
@@ -141,6 +143,14 @@ module Deis
|
|
141
143
|
perform :domains, app: app_id
|
142
144
|
end
|
143
145
|
|
146
|
+
def add_domain(app_id, domain)
|
147
|
+
perform :add_domain, { app: app_id }, domain: domain
|
148
|
+
end
|
149
|
+
|
150
|
+
def remove_domain(app_id, domain)
|
151
|
+
perform :remove_domain, { app: app_id, domain: domain }
|
152
|
+
end
|
153
|
+
|
144
154
|
def builds(app_id)
|
145
155
|
perform :builds, app: app_id
|
146
156
|
end
|
@@ -167,7 +177,9 @@ module Deis
|
|
167
177
|
login unless @token
|
168
178
|
|
169
179
|
verb, path = @@methods[method_sym]
|
170
|
-
path
|
180
|
+
# Interpolate path modifies the path instead of only returning the new one.
|
181
|
+
# hence we duplicate it so the original is never modified.
|
182
|
+
path = interpolate_path(path.dup, interpolations)
|
171
183
|
|
172
184
|
options = {
|
173
185
|
headers: @headers,
|