sqreen 1.4.3 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/sqreen/configuration.rb +4 -1
- data/lib/sqreen/frameworks/generic.rb +3 -1
- data/lib/sqreen/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6d96899ae72184cb34509aab39eba75cb2ba0cf8
|
4
|
+
data.tar.gz: 4201f6dbc906404d35dfb4352a32f4b1b2cc9775
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 63b4dc8db5a2709f720614ecf0e8b57fd91648ce02124a6fafd083435aa3c8d7e6c1de5b877c4b65be1aa9e7adb5214b93861b93e3e50d842d21f74967b76570
|
7
|
+
data.tar.gz: f589404093b80c59cf48680f4de58b2b3e8ebd164f5912ed4daa4b6a8c3b0de0348581fab382ae912ae4e5cc134d3883818f13e6c86998e833e65fc043c83b4b
|
data/lib/sqreen/configuration.rb
CHANGED
@@ -2,6 +2,7 @@
|
|
2
2
|
# Please refer to our terms for more information: https://www.sqreen.io/terms.html
|
3
3
|
|
4
4
|
require 'yaml'
|
5
|
+
require 'erb'
|
5
6
|
require 'sqreen/performance_notifications/newrelic'
|
6
7
|
|
7
8
|
module Sqreen
|
@@ -24,6 +25,8 @@ module Sqreen
|
|
24
25
|
CONFIG_FILE_BY_ENV = 'SQREEN_CONFIG_FILE'.freeze
|
25
26
|
|
26
27
|
CONFIG_DESCRIPTION = [
|
28
|
+
{ :env => :SQREEN_DISABLE, :name => :disable,
|
29
|
+
:default => false },
|
27
30
|
{ :env => :SQREEN_URL, :name => :url,
|
28
31
|
:default => 'https://back.sqreen.io' },
|
29
32
|
{ :env => :SQREEN_TOKEN, :name => :token,
|
@@ -104,7 +107,7 @@ module Sqreen
|
|
104
107
|
end
|
105
108
|
|
106
109
|
def parse_configuration_file(path)
|
107
|
-
res = YAML.
|
110
|
+
res = YAML.load(ERB.new(File.read(path)).result)
|
108
111
|
return {} unless res.is_a?(Hash)
|
109
112
|
if @framework
|
110
113
|
env = @framework.framework_infos[:environment]
|
@@ -143,7 +143,9 @@ module Sqreen
|
|
143
143
|
|
144
144
|
# Should the agent not be starting up?
|
145
145
|
def prevent_startup
|
146
|
-
:irb if $0 == 'irb'
|
146
|
+
return :irb if $0 == 'irb'
|
147
|
+
return if sqreen_configuration.nil?
|
148
|
+
return :config_disable if sqreen_configuration.get(:disable)
|
147
149
|
end
|
148
150
|
|
149
151
|
# Instrument with our rules when the framework as finished loading
|
data/lib/sqreen/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sqreen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sqreen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: execjs
|