brpm_module_brpm 0.1.21 → 0.1.22
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 +8 -8
- data/config.yml +1 -1
- data/lib/brpm_rest_client.rb +7 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDJkNTI5NjRkZGRhYjk0YTllODNiNDg5YTc3Y2E1ZDk4MmY4NjljMA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
Y2Y0MjZlOTlhY2ExOGI5MGExN2FjYWE5NWQ0YWUxMDdmMTBkNDU3MQ==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ZWRjYTZjYTc3MmU4ZmFjMTU3NjQ4MjE4NTdmZjgyYzA4MjI1NTk2Yjg2MGY5
|
10
|
+
MTRjMzdmMGFmNWU5ZDFmMDdmNzUxMzU2ZDc3YTFmODFjNmIyZDJmMmRmOTQ4
|
11
|
+
MjM0MzQ2NDdhM2E1ZDk1MDBkM2M4NTBmYWE0YWUxOWEyYTk3ZDA=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NzVkZjJjMDNkYmM1NTQ3MTY2MmExZWZlNjc3YTQyZjBlN2MyNmRiMTU1M2U2
|
14
|
+
YTk0MGEwYTcwNDU5ODc4NGQ1NThjMDYxMGFhZWI1NTBhYWVmMWM3OTE3ZmY3
|
15
|
+
OGU1NTlhYmY0ZWEwMzIzMzUxZWRiZGE4NWJhZjM5Y2NmZGFjZTA=
|
data/config.yml
CHANGED
data/lib/brpm_rest_client.rb
CHANGED
@@ -1523,7 +1523,7 @@ class BrpmRestClient
|
|
1523
1523
|
if result["code"] == 404
|
1524
1524
|
result_hash = nil
|
1525
1525
|
else
|
1526
|
-
raise "Could not find list item #{
|
1526
|
+
raise "Could not find list item #{list_item_name} in list #{list_name}: #{result["error_message"]}"
|
1527
1527
|
end
|
1528
1528
|
end
|
1529
1529
|
|
@@ -1636,7 +1636,11 @@ class BrpmRestClient
|
|
1636
1636
|
result = brpm_get "v1/scripts?filters[name]=#{name}"
|
1637
1637
|
|
1638
1638
|
if result["status"] == "success"
|
1639
|
-
|
1639
|
+
if result["response"]
|
1640
|
+
result_hash = result["response"].first
|
1641
|
+
else
|
1642
|
+
result_hash = nil
|
1643
|
+
end
|
1640
1644
|
else
|
1641
1645
|
if result["code"] == 404
|
1642
1646
|
result_hash = nil
|
@@ -1692,7 +1696,7 @@ class BrpmRestClient
|
|
1692
1696
|
|
1693
1697
|
def create_or_update_script(script)
|
1694
1698
|
BrpmAuto.log "Checking if the corresponding script already exists ..."
|
1695
|
-
existing_script = get_script_by_name
|
1699
|
+
existing_script = get_script_by_name(script["name"])
|
1696
1700
|
|
1697
1701
|
if existing_script.nil?
|
1698
1702
|
BrpmAuto.log "Script doesn't exist yet."
|