capdocker 1.0.71 → 1.0.72

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/capdocker.gemspec +1 -1
  3. data/lib/auth.rb +6 -10
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 680ddd6c4efe538b28e306dcf90836bd21dc9418
4
- data.tar.gz: 294d4d3a5438d58336cf21c59e42c67a3f28a9f1
3
+ metadata.gz: 2aac75b4744c029eaab07e73490e8e18ea64ac62
4
+ data.tar.gz: 0bc1f777c5891756823985f85e885d6ca9c3726d
5
5
  SHA512:
6
- metadata.gz: f5d62e790f33e3c5c2c8267cb04850ee12cd18cbd333be3acc1a274086493a08ead899d214d0d14b920b6f8d91f1240492940cae76ccb56e88cda6421ceb2a07
7
- data.tar.gz: 87756d6b4b81a546a62d75ee1492fda8b6a94abd30be493e9de51442e8b1ec3d1e4cd20567171d6bb1e850c65a533e74c8514fd9b75d2cfe223b2091198a36fd
6
+ metadata.gz: 27cb353ac582d6cbd6475e7237557249722e97cb6ecd92b818f784a404f776c6dd2889de9247056677870896e99413b6447f69c62164eabc0ac839073c70219d
7
+ data.tar.gz: 00952241deaab1556d26697116c71354448b41d689e77a055edb625dfa7db93434780d05657b99b197ba487d693f821b15fdbf1ddd2f945e1414d7ba066e29cd
data/capdocker.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{capdocker}
5
- s.version = "1.0.71"
5
+ s.version = "1.0.72"
6
6
  s.authors = ["Ross Riley", "One Black Bear"]
7
7
  s.email = %q{ross@oneblackbear.com}
8
8
  s.date = Time.now
data/lib/auth.rb CHANGED
@@ -16,9 +16,8 @@ Capistrano::Configuration.instance(:must_exist).load do
16
16
  if !n[auth_base]
17
17
  user = Capistrano::CLI.ui.ask("Account Name: ")
18
18
  tok =Capistrano::CLI.ui.ask("Account Token: ")
19
- result = JSON.parse(
20
- Net::HTTP.get_response(URI("http://#{auth_base}/account/auth/?account=#{user}&token=#{tok}"))
21
- )
19
+ uri = URI("http://#{auth_base}/account/auth/?account=#{user}&token=#{tok}")
20
+ result = JSON.parse(Net::HTTP.get_response(uri))
22
21
  n[auth_base] = result["success"], result["token"]
23
22
  n.save
24
23
  end
@@ -31,20 +30,17 @@ Capistrano::Configuration.instance(:must_exist).load do
31
30
  desc "After a successful login, connect to the deploy server and receive deploy information"
32
31
  task :get_deploy do
33
32
  login
34
- result = JSON.parse(
35
- Net::HTTP.get_response(URI("http://#{auth_base}/account/appinfo/?account=#{auth_account}&token=#{auth_token}&app=#{application}"))
36
- )
33
+ uri = URI("http://#{auth_base}/account/appinfo/?account=#{auth_account}&token=#{auth_token}&app=#{application}")
34
+ result = JSON.parse(Net::HTTP.get_response(uri))
37
35
  setup_app if result["error"]
38
36
  end
39
37
 
40
38
  desc "After a successful login, connect to the deploy server and receive deploy information"
41
39
  task :setup_app do
42
40
  login
41
+ uri = URI("http://#{auth_base}/account/appcreate/?account=#{auth_account}&token=#{auth_token}")
43
42
  result = JSON.parse(
44
- Net::HTTP.post_form(
45
- URI("http://#{auth_base}/account/appcreate/?account=#{auth_account}&token=#{auth_token}"),
46
- 'app' => application
47
- )
43
+ Net::HTTP.post_form(uri, 'app' => application)
48
44
  )
49
45
  puts result
50
46
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capdocker
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.71
4
+ version: 1.0.72
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ross Riley