mic_monitor_gem 0.3.5 → 0.3.6
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.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e9e0473ec1963ee4e599db92c0a8b435ff20fd7752cca355ab230dbd593e6a28
|
4
|
+
data.tar.gz: 94eb6415ee30dee2f8685d7540974f1e9f41b7e00e42f85f0ae55af94c6b7502
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 999e146f3a0e816849c235b94cd991cbc061d978353b0d37bc131236035bfd887433c7437185e34c26e9d53821654b51e211702905ab205be1b5c85d7a413706
|
7
|
+
data.tar.gz: 8e75865a6a733ef0b2a257a55f6eba895e6f48956fd030029b70c47c7eff24f95794710a580cb3c0cb4c50c7b80d3ec3cba0a27d377a0f84a2a424c8b478c072
|
@@ -3,26 +3,8 @@ module MicMonitorGem
|
|
3
3
|
class InstallGenerator < Rails::Generators::Base
|
4
4
|
source_root File.expand_path('templates', __dir__)
|
5
5
|
|
6
|
-
GEM_PATH = "#{Rails.root}/config/initializers/mic_monitor_gem.rb"
|
7
|
-
|
8
6
|
def create_file_mic_monitor_gem
|
9
|
-
template 'mic_monitor_gem.rb',
|
10
|
-
end
|
11
|
-
|
12
|
-
def add_config_email
|
13
|
-
append_to_file GEM_PATH do
|
14
|
-
<<-'RUBY'
|
15
|
-
if Rails.env.production?
|
16
|
-
Rails.application.config.middleware.use ExceptionNotification::Rack,
|
17
|
-
email: {
|
18
|
-
deliver_with: :deliver, # Rails >= 4.2.1 do not need this option since it defaults to :deliver_now
|
19
|
-
email_prefix: ENV['EMAIL_PREFIX'],
|
20
|
-
sender_address: ENV['SENDER_ADDRESS'],
|
21
|
-
exception_recipients: ENV['EXCEPTION_RECINPIENTS']
|
22
|
-
}
|
23
|
-
end
|
24
|
-
RUBY
|
25
|
-
end
|
7
|
+
template 'mic_monitor_gem.rb', 'config/initializers/mic_monitor_gem.rb'
|
26
8
|
end
|
27
9
|
end
|
28
10
|
end
|
@@ -0,0 +1,9 @@
|
|
1
|
+
if Rails.env.production?
|
2
|
+
Rails.application.config.middleware.use ExceptionNotification::Rack,
|
3
|
+
email: {
|
4
|
+
deliver_with: :deliver, # Rails >= 4.2.1 do not need this option since it defaults to :deliver_now
|
5
|
+
email_prefix: ENV['EMAIL_PREFIX'],
|
6
|
+
sender_address: ENV['SENDER_ADDRESS'],
|
7
|
+
exception_recipients: ENV['EXCEPTION_RECINPIENTS']
|
8
|
+
}
|
9
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mic_monitor_gem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mic-locnv
|
@@ -21,6 +21,7 @@ files:
|
|
21
21
|
- app/controller/mic_monitor_gem/ping_controller.rb
|
22
22
|
- config/routes.rb
|
23
23
|
- lib/generators/mic_monitor_gem/install_generator.rb
|
24
|
+
- lib/generators/mic_monitor_gem/template/mic_monitor_gem.rb
|
24
25
|
- lib/mic_monitor_gem.rb
|
25
26
|
- lib/mic_monitor_gem/engine.rb
|
26
27
|
- lib/mic_monitor_gem/version.rb
|