proboscis_cli 0.0.8 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9b08e20f2e8f4a6771b7a8192a86a2083c169546137f1a0b069bdb4fb9bf6648
4
- data.tar.gz: f63e3d0c12e1563317e2d4034172bc239b51d3f5690e6c72a9bacd45b4897b73
3
+ metadata.gz: acb31aaf3b03cb84ad89586625715ed8411b4ea360507d7f18f25061035fee17
4
+ data.tar.gz: 4f8dfc32ba55307289e5ed78c8e6c2f67d0d543dcb5590905e4ad788b91a64da
5
5
  SHA512:
6
- metadata.gz: 9be97117c7a5d2d6efa5b6f00ab6dd2f9cc29c13e0e19e49fb5b8983a52bfa8ab49c5ae631cb5b2f72d8d77fa1b87575d417b58c4a71fe6a24eec0ff745d5265
7
- data.tar.gz: 85ec027dbac647f5479cfc6b573d43b0a8fc1a0678fba499e9d32e52a175c6abe90cc7ce213883a76376a877a237da72dc464fe6317d95667bab1f02b1798114
6
+ metadata.gz: c85d27624a9ff37a6b722915cfaf145101e1883d9efd521b07a6cf5e900882bada72fcb1ae9a6a5bfa11584e2b186a92a99b899abfe0310e5bbaadba443fbfd5
7
+ data.tar.gz: a9b24c998096cf19447c697945a0df39f6ba7fe8dd7c2b463ab34051691f4bfc697215e93cc28e90871d05c98f16fc6cebfb67cf8a252d3137848f59c70a2b0a
@@ -1,3 +1,3 @@
1
1
  module ProboscisCli
2
- VERSION = '0.0.8'
2
+ VERSION = '0.1.1'
3
3
  end
data/lib/proboscis_cli.rb CHANGED
@@ -11,7 +11,7 @@ end
11
11
 
12
12
  class Server < Machine
13
13
  def self.ip(auth_code, host, environment, subdomain, type, subpath)
14
- response = HTTParty.get("#{host}/api/api/hives/#{subdomain}/#{type}", headers: {"X-Authorization" => auth_code})
14
+ response = HTTParty.get("#{host}/api/web/hives/#{subdomain}/#{type}", headers: {"X-Authorization" => auth_code})
15
15
  if response.code != 200
16
16
  puts "Unable to fetch details for domain #{subdomain}"
17
17
  exit -1
@@ -35,7 +35,7 @@ class CashServer < Server
35
35
  if subpath == 'araneae'
36
36
  return @ipAddress
37
37
  end
38
- res = HTTParty.get("http://#{@ipAddress}/admin/hosts", headers: {'X-Auth-Key': self.param(environment, 'token')})
38
+ res = HTTParty.get("https://#{subdomain}.delium.io/api/admin/hosts", headers: {'X-Auth-Key': self.param(environment, 'token')})
39
39
  if res.code != 200
40
40
  puts "Failed to get subpath details. #{res.code}"
41
41
  exit -1
@@ -68,7 +68,7 @@ class Worker < Machine
68
68
  end
69
69
 
70
70
  def self.client_list(environment)
71
- response = HTTParty.get("#{@host}/api/api/clients", headers: {"X-Authorization" => @auth_code})
71
+ response = HTTParty.get("#{@host}/api/web/clients", headers: {"X-Authorization" => @auth_code})
72
72
  if response.code != 200
73
73
  puts "Unable to get the client list.."
74
74
  exit -1
@@ -77,7 +77,7 @@ class Worker < Machine
77
77
  end
78
78
 
79
79
  def self.client(environment, client_id)
80
- response = HTTParty.get("#{@host}/api/api/clients/#{client_id["id"]}/products", headers: {"X-Authorization" => @auth_code})
80
+ response = HTTParty.get("#{@host}/api/web/clients/#{client_id["id"]}/products", headers: {"X-Authorization" => @auth_code})
81
81
  if response.code != 200
82
82
  puts "Unable to fetch details of client with id #{client_id}"
83
83
  exit -1
@@ -127,10 +127,10 @@ class Proboscis
127
127
  end
128
128
 
129
129
  def self.get_machine(target, type)
130
- if type == 'c'
131
- target == 'server' ? Server : Worker
132
- else
130
+ if type == 'CASH_REPLENISHMENT'
133
131
  target == 'server' ? CashServer : CashWorker
132
+ else
133
+ target == 'server' ? Server : Worker
134
134
  end
135
135
  end
136
136
 
@@ -1,10 +1,10 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'proboscis_cli'
3
- s.version = '0.0.8'
3
+ s.version = '0.1.1'
4
4
  s.date = '2018-04-10'
5
5
  s.summary = "A cli client for proboscis"
6
6
  s.description = "A cli client for proboscis"
7
- s.authors = ["Simon Roy", "Arvind"]
7
+ s.authors = ["Delium engineering"]
8
8
  s.email = 'info@delium.co'
9
9
  s.homepage =
10
10
  'http://rubygems.org/gems/proboscis_cli'
metadata CHANGED
@@ -1,11 +1,10 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: proboscis_cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
- - Simon Roy
8
- - Arvind
7
+ - Delium engineering
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
@@ -88,7 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
88
87
  - !ruby/object:Gem::Version
89
88
  version: '0'
90
89
  requirements: []
91
- rubygems_version: 3.0.4
90
+ rubygems_version: 3.3.7
92
91
  signing_key:
93
92
  specification_version: 4
94
93
  summary: A cli client for proboscis