apcera 0.1.6.10 → 0.1.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e55d0b1fa5cd3e1c80d500d49a658a48e569b004
4
- data.tar.gz: 68dd8e58f8c4ee61bca988e47d5b370fe318b9cd
3
+ metadata.gz: 69a59e9b2ab5e6603c1196de06fc345facc8a71f
4
+ data.tar.gz: 4bd6eb59b4c6c04d4bf0db816576936573c76730
5
5
  SHA512:
6
- metadata.gz: ef9456f8a30fb649a29dccb7cb2ffb92810288116be15b94e06190e56fc9eb466791a3fa6d464f7473f7ef4ae0e3c234e248b4c84c71ca24d56978880e39be55
7
- data.tar.gz: 36fc1115e14fbee71fc7abd523df4b2785ccfc9910b03b0a8f78ab30de78e2e934d8f0859d5fa5efa9f7983a65ac5dd725e61c56aef01f5caa8c7fae0fa19f41
6
+ metadata.gz: 2512f1cb55672d0f533c57dd9f407cb27bc2036e5bf628365e48905feda1c22073ea9925c400d9a45e0770020b6a839b29accbf9b4cf8f8f24137040d7eb3b04
7
+ data.tar.gz: 0e3819ce69b0c90d41ad5683c885f2fe742e5eb3428511624d4b0c4655877a33051ef84e0b8ea9d3f869f4b334be924ef9b18ef10040629793ed3ec11e6e449f
@@ -24,7 +24,8 @@ module Apcera
24
24
  @user_agent = "ruby-swagger-#{VERSION}"
25
25
  @default_headers = {
26
26
  'Content-Type' => "application/#{@format.downcase}",
27
- 'User-Agent' => @user_agent
27
+ 'User-Agent' => @user_agent,
28
+ 'Expect:' => ""
28
29
  }
29
30
  end
30
31
 
@@ -1,3 +1,3 @@
1
1
  module Apcera
2
- VERSION = "0.1.6.10"
2
+ VERSION = "0.1.7.0"
3
3
  end
@@ -94,8 +94,13 @@ class ApceraAuth
94
94
  @domain = parts.last
95
95
 
96
96
  @api_host = "api.#{@domain}"
97
- @auth_host = "auth.#{@domain}"
97
+
98
+ # Have to be running against a 2.x cluster or later for this to work. Older
99
+ # Clusters want the auth host to be "auth.xxx" not or "gauth.xxx"
100
+ #
101
+ @auth_host = "gauth.#{@domain}"
98
102
  @base_api_url = "#{scheme}://#{@api_host}"
103
+
99
104
  @base_auth_url = "#{scheme}://#{@auth_host}"
100
105
 
101
106
  # if the $HTTP_URI is set then we are in app_token mode, and auth is done.
@@ -741,7 +746,17 @@ class ApceraApiHelper
741
746
 
742
747
  puts "Scaling #{job_fqn} from #{job.num_instances} to #{number_of_instances} "
743
748
  job.num_instances = number_of_instances
744
- self.update_job(job)
749
+ puts "Payload is #{job.to_json}"
750
+ begin
751
+ Timeout.timeout(10) do
752
+ self.update_job(job)
753
+ end
754
+ rescue Timeout::Error
755
+ puts '========== REQUEST TO API TIMED OUT =============='
756
+ end
757
+ STDOUT.flush
758
+
759
+ puts "DONE Scaling #{job_fqn} from #{job.num_instances} to #{number_of_instances}"
745
760
  end
746
761
 
747
762
  def update_job(job)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apcera
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6.10
4
+ version: 0.1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jamie Smith
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-27 00:00:00.000000000 Z
11
+ date: 2016-08-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus