production_chain 0.0.8 → 0.0.9

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: 7d25b0b389d996fd8a2eb5a4420ae6ca99da53bd
4
- data.tar.gz: 38907458fc71a7f76903a0160269979625571688
3
+ metadata.gz: 27f4c63b2b59b5961d82c5ba0b89cbb9f5ec3bfc
4
+ data.tar.gz: b00098209e651d32b156eee4d4cc7bb04b1a653c
5
5
  SHA512:
6
- metadata.gz: 9a35dfab65d00d52b86a25a987250fc73e1803095f8ed499d186978c784466b152e7a26b2442f3739995731659e10e0b5113fcc00d0427ecc3430bc3ff87524b
7
- data.tar.gz: 7f1897a53d65ded576bbbf4d8a45a1d08d7fc7241c0e505579de87769fbb50a74b3d7334745dae71d57fdc6e41bcc48e1fb0dd3c0b9bb25daaa4519eea4d9ce3
6
+ metadata.gz: 2c8621030e67cc6455defbc345cec128c8af428b2924b6b41b812c84a646d136a380e2e51a990a692cc4bded569e20a366be353f8053f6d188f3bafd76105c7d
7
+ data.tar.gz: c73cdee146196d5e5eccca895c68aa474489c4cf13eb2552b63c2a4fdff732c4a0902459d4f45bd484323e2630d40f42f8a5239f459649bd254f6054f6f02630
@@ -32,13 +32,19 @@ private
32
32
  type = filename == "mongoid" ? "mongodb" : config_file[Rails.env]['adapter']
33
33
  if type == "mongodb" && config_file[Rails.env]["sessions"].present?
34
34
  # mongoid 3
35
- return [
36
- type,
37
- config_file[Rails.env]['sessions']['default']['database'],
38
- config_file[Rails.env]['sessions']['default']['username'],
39
- config_file[Rails.env]['sessions']['default']['password'],
40
- config_file[Rails.env]['sessions']['default']['hosts'].first || "127.0.0.1"
41
- ]
35
+ if config_file[Rails.env]['sessions']['default']['uri']
36
+ require 'uri'
37
+ uri = URI.parse config_file[Rails.env]['sessions']['default']['uri']
38
+
39
+ return [type, uri.path[1..-1], uri.user, uri.password, (uri.host || "127.0.0.1")]
40
+ else
41
+ return [
42
+ type,
43
+ config_file[Rails.env]['sessions']['default']['database'],
44
+ config_file[Rails.env]['sessions']['default']['username'],
45
+ config_file[Rails.env]['sessions']['default']['password'],
46
+ config_file[Rails.env]['sessions']['default']['hosts'] || "127.0.0.1"
47
+ ]
42
48
  else
43
49
  return [
44
50
  type,
@@ -1,3 +1,3 @@
1
1
  module ProductionChain
2
- VERSION = '0.0.8'
2
+ VERSION = '0.0.9'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: production_chain
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Novelys
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-03-03 00:00:00.000000000 Z
11
+ date: 2014-04-08 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A rails plugin that incorporate various libs, recipes and tasks
14
14
  email: