aptible-rails 0.1.3 → 0.1.4

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: ea41bb45af92b0239584a937a73ae6fe24adc447
4
- data.tar.gz: c79fec5c2ab29a3b67d483b651bb340f9541bd28
3
+ metadata.gz: 5086a88b4a3a6c43abe09edd3e5b56d55d1f01da
4
+ data.tar.gz: 27292c0c59ecc0b822a4ccc3f64af68d61ee3024
5
5
  SHA512:
6
- metadata.gz: cfef7463039136be1e97478d9d1a6aa59347c67647864baa279480f51ae22c15e46c23123ae00ae71d39d948263a08bbb5d4d5ef25e10f87375d7d1000afb356
7
- data.tar.gz: dff6707756fe115cc3844a3e2668d48c6822ba82bf42af6a2f8d95393416e160f3e4341755bca35c275a74229e33e937059ae2090fb3bfdaa5dc8f68fb45a75f
6
+ metadata.gz: 8bbea907f7262e0e7f98ee27a33cb6483953abea614b997584e5e62200ac010e784e98d658febbdfb8c89fcdd140c4fcc96537290a010a6d317efc02a21e6e89
7
+ data.tar.gz: 98e29b315e0e1a7389c1b06dca336274c43b5ee8fa64129580e2d24c605b29d0c65d6d611b21cc20f823d876490cc2d1e605d7b62f0ebca2d54749d921e29bdb
@@ -1,4 +1,5 @@
1
1
  require 'aptible/rails/controller'
2
+ require 'aptible/rails/routes_helper'
2
3
 
3
4
  module Aptible
4
5
  module Rails
@@ -13,7 +14,7 @@ module Aptible
13
14
  config.public_key = Aptible::Auth.public_key
14
15
  end
15
16
  rescue
16
- ::Rails.logger.warn 'Could not retrieve auth server public key'
17
+ raise 'Could not retrieve auth server public key'
17
18
  end
18
19
  end
19
20
  end
@@ -21,6 +22,10 @@ module Aptible
21
22
  initializer 'aptible.rails.controller' do
22
23
  ActionController::Base.send :include, Aptible::Rails::Controller
23
24
  end
25
+
26
+ initializer 'aptible.rails.routes_helper' do
27
+ ApplicationHelper.send :include, Aptible::Rails::RoutesHelper
28
+ end
24
29
  end
25
30
  end
26
31
  end
@@ -0,0 +1,88 @@
1
+ module Aptible
2
+ module Rails
3
+ module RoutesHelper
4
+ def main_url
5
+ 'https://www.aptible.com'
6
+ end
7
+
8
+ def about_url
9
+ main_url + '/about'
10
+ end
11
+
12
+ def audits_url
13
+ main_url + '/stressfree'
14
+ end
15
+
16
+ # Tumblr doesn't support HTTPS w/ our own domain
17
+ def blog_url
18
+ 'http://blog.aptible.com'
19
+ end
20
+
21
+ def compliance_url
22
+ ENV['APTIBLE_DASHBOARD_ROOT_URL'] + '/compliance'
23
+ end
24
+
25
+ def contact_url
26
+ main_url + '/contact'
27
+ end
28
+
29
+ def dashboard_url
30
+ ENV['APTIBLE_DASHBOARD_ROOT_URL']
31
+ end
32
+
33
+ def docs_url
34
+ main_url + '/docs'
35
+ end
36
+
37
+ def enterprise_url
38
+ main_url + '/enterprise'
39
+ end
40
+
41
+ def legal_url
42
+ main_url + '/legal'
43
+ end
44
+
45
+ def policy_url
46
+ ENV['APTIBLE_POLICY_ROOT_URL']
47
+ end
48
+
49
+ def pricing_url
50
+ main_url + '/pricing'
51
+ end
52
+
53
+ def privacy_url
54
+ main_url + '/privacy'
55
+ end
56
+
57
+ def security_url
58
+ main_url + '/privacy'
59
+ end
60
+
61
+ # Groove doesn't support HTTPS w/ our own domain
62
+ def support_url
63
+ 'http://help.aptible.com'
64
+ end
65
+
66
+ # Statuspage.io requires a business-tier plan for SSL
67
+ def status_url
68
+ 'http://status.aptible.com/'
69
+ end
70
+
71
+ def risk_url
72
+ ENV['APTIBLE_RISK_ROOT_URL']
73
+ end
74
+
75
+ # def roles_url
76
+ # ENV['APTIBLE_DASHBOARD_ROOT_URL'] + '/roles'
77
+ # end
78
+
79
+ def terms_url
80
+ main_url + '/terms'
81
+ end
82
+
83
+ def training_url
84
+ main_url + '/training'
85
+ end
86
+ end
87
+ end
88
+ end
@@ -1,5 +1,5 @@
1
1
  module Aptible
2
2
  module Rails
3
- VERSION = '0.1.3'
3
+ VERSION = '0.1.4'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aptible-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Frank Macreery
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-03-20 00:00:00.000000000 Z
11
+ date: 2014-03-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem_config
@@ -140,6 +140,7 @@ files:
140
140
  - lib/aptible/rails.rb
141
141
  - lib/aptible/rails/controller.rb
142
142
  - lib/aptible/rails/railtie.rb
143
+ - lib/aptible/rails/routes_helper.rb
143
144
  - lib/aptible/rails/version.rb
144
145
  - spec/spec_helper.rb
145
146
  homepage: https://github.com/aptible/aptible-rails
@@ -162,7 +163,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
162
163
  version: '0'
163
164
  requirements: []
164
165
  rubyforge_project:
165
- rubygems_version: 2.2.1
166
+ rubygems_version: 2.2.2
166
167
  signing_key:
167
168
  specification_version: 4
168
169
  summary: Rails helpers for Aptible service applications