standup 0.3.6 → 0.3.7
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +1 -3
- data/VERSION +1 -1
- data/lib/standup/scripts/base.rb +15 -0
- data/scripts/passenger/nginx.conf +2 -1
- data/scripts/webapp/webapp.conf +3 -1
- data/scripts/webapp.rb +3 -1
- data/standup.gemspec +1 -1
- metadata +3 -3
data/README.md
CHANGED
@@ -61,7 +61,7 @@ Script params are merged in `node-specific || global || script-defaults` manner.
|
|
61
61
|
0. Script file `config/standup/<script_name>.rb` will be copied from gem.
|
62
62
|
0. Script's own files, like configs etc. under `config/standup/<script_name>`, if any, will be copied from gem too.
|
63
63
|
0. You can edit them and standup will use them instead of default.
|
64
|
-
0. You can delete local script
|
64
|
+
0. You can delete local script file or its own files, then default ones will be used.
|
65
65
|
|
66
66
|
## Creating new scripts
|
67
67
|
|
@@ -90,8 +90,6 @@ For example, if you want to add `rescue` to your configuration, you need to:
|
|
90
90
|
|
91
91
|
- **?** Script sequences: rework default script as script sequence
|
92
92
|
|
93
|
-
- ERB processing for script files
|
94
|
-
|
95
93
|
## Copyright
|
96
94
|
|
97
95
|
Copyright (c) 2010 Ilia Ablamonov, Cloud Castle Inc.
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.7
|
data/lib/standup/scripts/base.rb
CHANGED
@@ -34,6 +34,17 @@ module Standup
|
|
34
34
|
nil
|
35
35
|
end
|
36
36
|
|
37
|
+
def with_processed_file filename
|
38
|
+
Dir.mktmpdir do |dir|
|
39
|
+
erb = ERB.new File.read(filename)
|
40
|
+
erb.filename = filename
|
41
|
+
result = erb.result get_binding
|
42
|
+
tmp_filename = File.expand_path File.basename(filename), dir
|
43
|
+
File.open(tmp_filename, 'w') {|f| f.write result}
|
44
|
+
yield tmp_filename
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
37
48
|
def self.execute
|
38
49
|
new.run
|
39
50
|
end
|
@@ -83,6 +94,10 @@ module Standup
|
|
83
94
|
end
|
84
95
|
result
|
85
96
|
end
|
97
|
+
|
98
|
+
def get_binding
|
99
|
+
binding
|
100
|
+
end
|
86
101
|
end
|
87
102
|
end
|
88
103
|
end
|
data/scripts/webapp/webapp.conf
CHANGED
data/scripts/webapp.rb
CHANGED
@@ -24,7 +24,9 @@ Standup.script :node do
|
|
24
24
|
|
25
25
|
sudo 'chown -R nobody:nogroup /opt/webapp'
|
26
26
|
|
27
|
-
|
27
|
+
with_processed_file script_file('webapp.conf') do |file|
|
28
|
+
scripts.passenger.add_server_conf file
|
29
|
+
end
|
28
30
|
end
|
29
31
|
|
30
32
|
protected
|
data/standup.gemspec
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: standup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 29
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 7
|
10
|
+
version: 0.3.7
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Ilia Ablamonov
|