opsmgr 0.34.0 → 0.34.1

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: 79c4d9ba31bb27d2f4b65ed0d02f1ddb30a39724
4
- data.tar.gz: d6e5eca5bece6e0914d3e8da79bf11ea45a6fd08
3
+ metadata.gz: c3d410f8f4abbff124cdff2ffd9b15d0f8b24410
4
+ data.tar.gz: 6a3eda4d7544fa72a16c327ebb6bf1876ac90074
5
5
  SHA512:
6
- metadata.gz: aa084e0c3b6fe3729646bec8e725b5f7a6d9ad7dde7ecbf4bdcedb63b95376d42409e626d3a54c65972cdd01c96e1836bf9798e523c542e52f1e3cc4f93e6216
7
- data.tar.gz: b7ae4c288832a47d61538142009cdb7cf81a9bdd46b60ad2923f4c3831b08d2fb5b89b4bd563ef623885d9cbb65d0c22218f39852fa926f19135870e0fd51156
6
+ metadata.gz: a5ac0eb7e7dba197de213665d16d17977dd4ba2ca4df39ba1a7b7b3011e8e9451c7c7e5f72f8eddd43281790f7853823b77b761f8170d065feb3bc86c92a50be
7
+ data.tar.gz: 27a3eb527eedac0a6d3c75111d15097ecfa4ca003380ce8c681ecd68ee47f2a011463aa45b55f8dc695051346f814840f06959fe3dab925135b57aacb48483b1
@@ -145,14 +145,7 @@ module Opsmgr
145
145
  end
146
146
 
147
147
  def create_the_first_user
148
- if Gem::Version.new(@om_version) < Gem::Version.new('1.7')
149
- req = Net::HTTP::Post.new(endpoints.api_user_path)
150
- req.set_form_data(
151
- 'user[user_name]' => web_auth_user,
152
- 'user[password]' => web_auth_password,
153
- 'user[password_confirmation]' => web_auth_password,
154
- )
155
- else
148
+ if Gem::Version.new(@om_version) >= Gem::Version.new('1.6')
156
149
  req = Net::HTTP::Post.new(endpoints.api_setup_path)
157
150
  req.set_form_data(
158
151
  'setup[user_name]' => web_auth_user,
@@ -160,6 +153,13 @@ module Opsmgr
160
153
  'setup[password_confirmation]' => web_auth_password,
161
154
  'setup[eula_accepted]' => true
162
155
  )
156
+ else
157
+ req = Net::HTTP::Post.new(endpoints.api_user_path)
158
+ req.set_form_data(
159
+ 'user[user_name]' => web_auth_user,
160
+ 'user[password]' => web_auth_password,
161
+ 'user[password_confirmation]' => web_auth_password,
162
+ )
163
163
  end
164
164
 
165
165
  http.request(req)
@@ -205,7 +205,7 @@ module Opsmgr
205
205
  import_secret_parameter_name => password
206
206
  )
207
207
 
208
- add_auth_header(req) unless Gem::Version.new(@om_version) >= Gem::Version.new('1.7')
208
+ add_auth_header(req)
209
209
 
210
210
  response = http.request(req)
211
211
 
@@ -1,5 +1,5 @@
1
1
  module Opsmgr
2
- VERSION = '0.34.0'
2
+ VERSION = '0.34.1'
3
3
  end
4
4
  # Copyright (c) 2014-2015 Pivotal Software, Inc.
5
5
  # All rights reserved.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opsmgr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.34.0
4
+ version: 0.34.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Release Engineering
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-29 00:00:00.000000000 Z
11
+ date: 2016-03-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake