openteam-commons 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
@@ -5,11 +5,15 @@ CURRENT_PATH=$(dirname $(dirname $(realpath $0)))
|
|
5
5
|
PROJECT_GROUP=$(basename $(dirname $CURRENT_PATH))
|
6
6
|
PROJECT_NAME=$(basename $(dirname $(dirname $(realpath $0))))
|
7
7
|
|
8
|
-
|
8
|
+
pushd $CURRENT_PATH
|
9
9
|
|
10
10
|
if [ $(/usr/bin/uname) == "FreeBSD" ]; then
|
11
11
|
git checkout Gemfile.lock
|
12
|
+
RC_PATH=/usr/local/etc/rc.d/
|
13
|
+
else
|
14
|
+
RC_PATH=/etc/init.d/
|
12
15
|
fi
|
16
|
+
RC_SCRIPT=${RC_PATH}/${PROJECT_GROUP}-${PROJECT_NAME}
|
13
17
|
|
14
18
|
git pull
|
15
19
|
|
@@ -19,20 +23,14 @@ if [ -f "config/database.yml" ]; then
|
|
19
23
|
bin/rake db:migrate
|
20
24
|
fi
|
21
25
|
|
22
|
-
if [ $
|
23
|
-
|
24
|
-
else
|
25
|
-
RC_PATH=/etc/init.d/
|
26
|
+
if [ "x${1}" == "x--assets" ]; then
|
27
|
+
bin/rake assets:clean assets:precompile
|
26
28
|
fi
|
27
29
|
|
28
|
-
RC_SCRIPT=${RC_PATH}/${PROJECT_GROUP}-${PROJECT_NAME}
|
29
|
-
|
30
30
|
if [ -f ${RC_SCRIPT} ]; then
|
31
31
|
${RC_SCRIPT} reload
|
32
32
|
fi
|
33
33
|
|
34
|
-
if [ "x${1}" == "xca" ]; then
|
35
|
-
bin/rake assets:clean assets:precompile
|
36
|
-
fi
|
37
|
-
|
38
34
|
bin/rake airbrake:deploy TO=production
|
35
|
+
|
36
|
+
popd
|
@@ -6,21 +6,17 @@ module OpenteamCommons
|
|
6
6
|
isolate_namespace OpenteamCommons
|
7
7
|
|
8
8
|
config.before_configuration do
|
9
|
-
|
10
|
-
end
|
11
|
-
|
12
|
-
config.before_initialize do
|
13
|
-
setup_airbrake
|
9
|
+
read_settings
|
14
10
|
end
|
15
11
|
|
16
12
|
config.after_initialize do
|
13
|
+
setup_airbrake
|
17
14
|
setup_locale
|
18
|
-
setup_log_level
|
19
15
|
setup_secret
|
20
16
|
end
|
21
17
|
|
22
18
|
private
|
23
|
-
def
|
19
|
+
def read_settings
|
24
20
|
Settings.read(Rails.root.join('config', 'settings.yml')) if Rails.root.join('config', 'settings.yml').exist?
|
25
21
|
|
26
22
|
Settings.defaults Settings.extract!(Rails.env)[Rails.env] || {}
|
@@ -39,9 +35,6 @@ module OpenteamCommons
|
|
39
35
|
Settings.define 'sso.url', :env_var => 'SSO_URL'
|
40
36
|
|
41
37
|
Settings.define 'storage.url', :env_var => 'STORAGE_URL'
|
42
|
-
|
43
|
-
Settings.define 'unicorn.workers', :env_var => 'UNICORN_WORKERS'
|
44
|
-
Settings.define 'unicorn.timeout', :env_var => 'UNICORN_TIMEOUT'
|
45
38
|
end
|
46
39
|
|
47
40
|
def setup_airbrake
|
@@ -65,9 +58,5 @@ module OpenteamCommons
|
|
65
58
|
def setup_locale
|
66
59
|
I18n.locale = I18n.default_locale
|
67
60
|
end
|
68
|
-
|
69
|
-
def setup_log_level
|
70
|
-
Rails.logger.level = ActiveSupport::BufferedLogger::Severity::WARN if Rails.env.production?
|
71
|
-
end
|
72
61
|
end
|
73
62
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openteam-commons
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-03-
|
12
|
+
date: 2012-03-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: airbrake
|
16
|
-
requirement: &
|
16
|
+
requirement: &16411500 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *16411500
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: configliere
|
27
|
-
requirement: &
|
27
|
+
requirement: &16409980 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *16409980
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: rails
|
38
|
-
requirement: &
|
38
|
+
requirement: &16408000 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: '0'
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *16408000
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: unicorn
|
49
|
-
requirement: &
|
49
|
+
requirement: &16406500 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ! '>='
|
@@ -54,7 +54,7 @@ dependencies:
|
|
54
54
|
version: '0'
|
55
55
|
type: :runtime
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *16406500
|
58
58
|
description: Description of OpenteamCommons.
|
59
59
|
email:
|
60
60
|
- mail@openteam.ru
|
@@ -90,7 +90,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
90
90
|
version: '0'
|
91
91
|
segments:
|
92
92
|
- 0
|
93
|
-
hash: -
|
93
|
+
hash: -316006890504474889
|
94
94
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
95
95
|
none: false
|
96
96
|
requirements:
|
@@ -99,7 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
99
99
|
version: '0'
|
100
100
|
segments:
|
101
101
|
- 0
|
102
|
-
hash: -
|
102
|
+
hash: -316006890504474889
|
103
103
|
requirements: []
|
104
104
|
rubyforge_project:
|
105
105
|
rubygems_version: 1.8.15
|