fpauser-vlad 2.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.autotest +25 -0
- data/Gemfile +1 -0
- data/Gemfile.lock +21 -0
- data/History.txt +206 -0
- data/Manifest.txt +23 -0
- data/README.txt +78 -0
- data/Rakefile +37 -0
- data/considerations.txt +91 -0
- data/doco/deploying-merb-with-vlad.txt +155 -0
- data/doco/deploying-sinatra-with-vlad.txt +119 -0
- data/doco/faq.txt +136 -0
- data/doco/getting_started.txt +61 -0
- data/doco/migration.txt +43 -0
- data/doco/perforce.txt +5 -0
- data/doco/variables.txt +79 -0
- data/lib/vlad.rb +78 -0
- data/lib/vlad/apache.rb +37 -0
- data/lib/vlad/core.rb +195 -0
- data/lib/vlad/maintenance.rb +20 -0
- data/lib/vlad/passenger.rb +8 -0
- data/lib/vlad/rails.rb +34 -0
- data/lib/vlad/subversion.rb +35 -0
- data/test/test_vlad.rb +209 -0
- data/test/test_vlad_subversion.rb +26 -0
- data/vladdemo.sh +97 -0
- metadata +116 -0
data/.autotest
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# -*- ruby -*-
|
2
|
+
|
3
|
+
require 'autotest/restart'
|
4
|
+
require 'autotest/rcov'
|
5
|
+
|
6
|
+
Autotest.add_hook :initialize do |at|
|
7
|
+
at.testlib = "minitest/autorun"
|
8
|
+
# at.extra_files << "../some/external/dependency.rb"
|
9
|
+
#
|
10
|
+
at.libs << ":../../rake-remote_task/dev/lib"
|
11
|
+
#
|
12
|
+
# at.add_exception 'vendor'
|
13
|
+
#
|
14
|
+
# at.add_mapping(/dependency.rb/) do |f, _|
|
15
|
+
# at.files_matching(/test_.*rb$/)
|
16
|
+
# end
|
17
|
+
#
|
18
|
+
# %w(TestA TestB).each do |klass|
|
19
|
+
# at.extra_class_map[klass] = "test/test_misc.rb"
|
20
|
+
# end
|
21
|
+
end
|
22
|
+
|
23
|
+
# Autotest.add_hook :run_command do |at|
|
24
|
+
# system "rake build"
|
25
|
+
# end
|
data/Gemfile
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
gemspec
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
fpauser-vlad (2.2.0)
|
5
|
+
fpauser-rake-remote_task (>= 2.0.3)
|
6
|
+
open4 (>= 0.9.0)
|
7
|
+
rake (>= 0.8.0)
|
8
|
+
|
9
|
+
GEM
|
10
|
+
specs:
|
11
|
+
fpauser-rake-remote_task (2.0.3)
|
12
|
+
open4 (>= 0.9.0)
|
13
|
+
rake (>= 0.8.0)
|
14
|
+
open4 (0.9.6)
|
15
|
+
rake (0.9.2)
|
16
|
+
|
17
|
+
PLATFORMS
|
18
|
+
ruby
|
19
|
+
|
20
|
+
DEPENDENCIES
|
21
|
+
fpauser-vlad!
|
data/History.txt
ADDED
@@ -0,0 +1,206 @@
|
|
1
|
+
=== 2.2.0 / 2011-02-18
|
2
|
+
|
3
|
+
* 5 minor enhancements:
|
4
|
+
|
5
|
+
* Added support for setting owner and group of deploy. (RichGuk)
|
6
|
+
* Allow shared_paths, mkdirs, and symlinks to be excluded (RichGuk/zaius)
|
7
|
+
* Cleaned up update task to correspond to rake-remote-task changes. (RichGuk)
|
8
|
+
* Do not run symlink commands if there are no operations to run. (jsmecham)
|
9
|
+
* Obey the umask across the board. (RichGuk)
|
10
|
+
|
11
|
+
* 2 bug fixes:
|
12
|
+
|
13
|
+
* Fixed migrate task shell cmd. (cheba)
|
14
|
+
* Fixed passenger touch file location. (richinsr)
|
15
|
+
|
16
|
+
=== 2.1.0 / 2010-07-15
|
17
|
+
|
18
|
+
* 1 major enhancement:
|
19
|
+
|
20
|
+
* Split out rake_remote_task.rb and vlad_test_case.rb (in rake-remote_task gem).
|
21
|
+
|
22
|
+
* 4 minor enhancements:
|
23
|
+
|
24
|
+
* Added :type config option, defaulting to rails
|
25
|
+
* Moved VladTestCase to Rake::TestCase (in rake-remote_task gem).
|
26
|
+
* Moved all Vlad exceptions to Rake (in rake-remote_task gem).
|
27
|
+
* Refactored rails specific values out of core. (raggi)
|
28
|
+
|
29
|
+
* 2 bug fixes:
|
30
|
+
|
31
|
+
* Clarified Rake.clear_tasks in faq
|
32
|
+
* Fixed output from vlad:invoke (pnc)
|
33
|
+
|
34
|
+
=== 2.0.0 / 2009-08-18
|
35
|
+
|
36
|
+
* 1 major enhancement:
|
37
|
+
|
38
|
+
* Removed all extra modules that we don't support in core anymore.
|
39
|
+
|
40
|
+
* 2 minor enhancements:
|
41
|
+
|
42
|
+
* Added test to show that false is a valid variable value.
|
43
|
+
* Moved vlad_test_case from test to lib to support 3rd party vlad modules.
|
44
|
+
|
45
|
+
=== 1.4.0 / 2009-06-23
|
46
|
+
|
47
|
+
* 1 major enhancement:
|
48
|
+
|
49
|
+
* Switched to passenger as default app server.
|
50
|
+
|
51
|
+
* 11 minor enhancements:
|
52
|
+
|
53
|
+
* #rsync now takes ANY number of arguments and expects to you add "host:".
|
54
|
+
* Added Rake::RemoteTask#get.
|
55
|
+
* Added doco for why we don't ship a deploy task
|
56
|
+
* Added links to example maintenance recipes
|
57
|
+
* Added multi-env doco to getting_started.txt
|
58
|
+
* Added svn-over-ssh faq item. gah.
|
59
|
+
* Flipped tests to minitest
|
60
|
+
* Merged global #role and Rake::RemoteTask::role.
|
61
|
+
* Moved all global methods to Rake::RemoteTask and wrote #external to clean up.
|
62
|
+
* Moved rake extensions to hoe so everyone can enjoy the fun.
|
63
|
+
* put names the tempfile based on the remote path to ease debugging
|
64
|
+
|
65
|
+
* 2 bug fixes:
|
66
|
+
|
67
|
+
* passenger:start_app wasn't using the latest_release path
|
68
|
+
* set/fetch wasn't dealing with a default of false well. (Seth Falcon)
|
69
|
+
|
70
|
+
=== 1.3.2 / 2009-03-16
|
71
|
+
|
72
|
+
* 3 minor enhancements:
|
73
|
+
|
74
|
+
* Added 'Deploying Merb with Vlad' by Graham Ashton.
|
75
|
+
* Added 'Deploying Sinatra with Vlad' by Graham Ashton.
|
76
|
+
* Core update task calls update with the actual revision once again
|
77
|
+
|
78
|
+
* 1 bug fix:
|
79
|
+
|
80
|
+
* Fix Git checkout/export methods. (Wilson)
|
81
|
+
|
82
|
+
=== 1.3.1 / 2009-03-06
|
83
|
+
|
84
|
+
* 4 minor enhancements:
|
85
|
+
|
86
|
+
* Added faq on how to clear/replace tasks. (mikehale)
|
87
|
+
* Added sudo_prompt variable.
|
88
|
+
* Added top level sudo method to compliment run. (woahdae)
|
89
|
+
* Set sudo_flags to default to ['-p Password:']. (mly)
|
90
|
+
|
91
|
+
* 3 bug fixes:
|
92
|
+
|
93
|
+
* Fixed prompts during rollback. (goodieboy)
|
94
|
+
* deploy_via went AWOL in subversion module.
|
95
|
+
* vlad:migrate ignored migrate_target directory. (tomklaasen)
|
96
|
+
|
97
|
+
=== 1.3.0 / 2009-03-04
|
98
|
+
|
99
|
+
* 9 major enhancements:
|
100
|
+
|
101
|
+
* Added darcs support. (Brian Palmer)
|
102
|
+
* Added git support. (Garry Dolley)
|
103
|
+
* Added lighttpd support.
|
104
|
+
* Added merb support. (Jamie Macey)
|
105
|
+
* Added passenger support. (Alan Harper)
|
106
|
+
* Added/merged god, nginx, thin, and maintenance tasks. (github clusterfuck)
|
107
|
+
* Allow set to specify that a proc value is :per_thread.
|
108
|
+
* Apply Mercurial SCM support patch. Closes ticket 13475
|
109
|
+
* remote_task now supports args and supplies task (by Daniel P. Kionka).
|
110
|
+
|
111
|
+
* 19 minor enhancements:
|
112
|
+
|
113
|
+
* Add role toplevel method similar to namespace.
|
114
|
+
* Added #put method that wraps up Tempfile/rsync pattern.
|
115
|
+
* Added #role toplevel method, similar to #namespace.
|
116
|
+
* Added FAQ for using vlad through a gateway.
|
117
|
+
* Added Phil Hagelburg's one-line multi-stage deployment patch
|
118
|
+
* Added rake tracing for rsync command.
|
119
|
+
* Added umask variable.
|
120
|
+
* Adds specific order to loading. Should fix a number of bugs.
|
121
|
+
* Extended vladdemo.sh to allow for N simulated hosts (mostly for testing)
|
122
|
+
* Fixed tempfile dependency in #put if you don't load lighttpd or perforce (yipstar)
|
123
|
+
* Mercurial now automatically initializes the repository. (Jamie Macey)
|
124
|
+
* Moved everything over to put.
|
125
|
+
* Now requires rake 0.8.1+.
|
126
|
+
* Parameterized 'head' into 'revision' variable (with head as default).
|
127
|
+
* Split shared symlink creation to a separate task. (Steve Purcell)
|
128
|
+
* Support rake 0.8.
|
129
|
+
* Switched to ThreadGroup for Action#execute
|
130
|
+
* Updated rakefile for new hoe abilities
|
131
|
+
* remote_task :role now allows an empty list of hosts.
|
132
|
+
|
133
|
+
* 11 bug fixes:
|
134
|
+
|
135
|
+
* Fixed vladdemo.rb, now uses my checkout for further stress testing.
|
136
|
+
* Moved core recipe to front. Was breaking mongrel setup.
|
137
|
+
* Added automatic client setup for perforce.
|
138
|
+
* Fix mercurial support.
|
139
|
+
* Fixed 'too many files' error.
|
140
|
+
* Fixed a lame warning in the tests.
|
141
|
+
* Fixed cleanup to actually properly clean up.
|
142
|
+
* Fixed rake var doco
|
143
|
+
* Moved generic app setup to core from mongrel.
|
144
|
+
* SSH flags are now an Array for proper inclusion in the command. (Guillaume Pierronnet)
|
145
|
+
* git archive now specifically specifies tar format. (knaveofdiamonds)
|
146
|
+
|
147
|
+
=== 1.1.1 / 2008-01-14
|
148
|
+
|
149
|
+
* 5 major enhancements:
|
150
|
+
|
151
|
+
* Support for Rake 0.8. Should still work for Rake 0.7.
|
152
|
+
* Added git support (contributed by Garry Dolley).
|
153
|
+
* Reviewed for accuracy by Evan Phoenix.
|
154
|
+
* Added lighttpd.rb
|
155
|
+
* Added automatic client setup for perforce.
|
156
|
+
* Added mercurial SCM support patch. Closes ticket 13475.
|
157
|
+
|
158
|
+
* 6 minor enhancements:
|
159
|
+
|
160
|
+
* Added #put method that wraps up Tempfile/rsync pattern.
|
161
|
+
* Added automatic p4 client setup for perforce.
|
162
|
+
* Added vladdemo.sh
|
163
|
+
* Moved everything over to put.
|
164
|
+
* Moved generic app setup to core from mongrel.
|
165
|
+
* Parameterized 'head' into 'revision' variable (with head as default).
|
166
|
+
|
167
|
+
* 1 bug fix
|
168
|
+
|
169
|
+
* Fixed cleanup to actually properly clean up.
|
170
|
+
|
171
|
+
=== 1.1.0 / 2007-09-12
|
172
|
+
|
173
|
+
* 3 major enhancements:
|
174
|
+
|
175
|
+
* Vlad.load now takes a hash of recipe overrides, eg: Vlad.load :web => :nginx.
|
176
|
+
See rdoc for defaults.
|
177
|
+
* Removed vlad_tasks.rb and split into vlad/apache.rb, vlad/mongrel.rb,
|
178
|
+
and vlad/core.rb.
|
179
|
+
* The flog ratio between capistrano+deps / vlad+deps is pi (or, damn close)!
|
180
|
+
|
181
|
+
* 12 minor enhancements:
|
182
|
+
|
183
|
+
* Added $TRACE to make it more available and cleaner to read.
|
184
|
+
* Added :svn_cmd variable.
|
185
|
+
* Added Rake.clear_tasks *str_or_regexp
|
186
|
+
* Added debug and mana_from_heaven tasks to Rakefile.
|
187
|
+
* Added more documentation.
|
188
|
+
* Added :rsync_cmd and :rsync_flags.
|
189
|
+
* Added :ssh_cmd and :ssh_flags.
|
190
|
+
* Added variable expansion to vlad:debug task.
|
191
|
+
* Removed :scm variable. Now a Vlad.load component/flavor/need-a-word-here.
|
192
|
+
* Removed :application var. Use it if you want it. We don't require it.
|
193
|
+
* Renamed :p4cmd to :p4_cmd.
|
194
|
+
* Renamed :rake var to :rake_cmd.
|
195
|
+
|
196
|
+
* 2 (important) bug fixes:
|
197
|
+
|
198
|
+
* HUGE: Fixed sudo hang bug #13072. Fix suggested by Chris Van Pelt.
|
199
|
+
* HUGE: Vlad.load calls user config last, allowing variable overrides.
|
200
|
+
ACK! Sorry!
|
201
|
+
|
202
|
+
=== 1.0.0 / 2007-08-04
|
203
|
+
|
204
|
+
* 1 major enhancement
|
205
|
+
|
206
|
+
* Birthday!
|
data/Manifest.txt
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
.autotest
|
2
|
+
History.txt
|
3
|
+
Manifest.txt
|
4
|
+
README.txt
|
5
|
+
Rakefile
|
6
|
+
considerations.txt
|
7
|
+
doco/deploying-merb-with-vlad.txt
|
8
|
+
doco/deploying-sinatra-with-vlad.txt
|
9
|
+
doco/faq.txt
|
10
|
+
doco/getting_started.txt
|
11
|
+
doco/migration.txt
|
12
|
+
doco/perforce.txt
|
13
|
+
doco/variables.txt
|
14
|
+
lib/vlad.rb
|
15
|
+
lib/vlad/apache.rb
|
16
|
+
lib/vlad/core.rb
|
17
|
+
lib/vlad/maintenance.rb
|
18
|
+
lib/vlad/passenger.rb
|
19
|
+
lib/vlad/rails.rb
|
20
|
+
lib/vlad/subversion.rb
|
21
|
+
test/test_vlad.rb
|
22
|
+
test/test_vlad_subversion.rb
|
23
|
+
vladdemo.sh
|
data/README.txt
ADDED
@@ -0,0 +1,78 @@
|
|
1
|
+
= Vlad the Deployer by the Ruby Hit Squad
|
2
|
+
|
3
|
+
* http://rubyhitsquad.com/
|
4
|
+
* http://rubyforge.org/projects/hitsquad/
|
5
|
+
|
6
|
+
== DESCRIPTION
|
7
|
+
|
8
|
+
Vlad the Deployer is pragmatic application deployment automation,
|
9
|
+
without mercy. Much like Capistrano, but with 1/10th the
|
10
|
+
complexity. Vlad integrates seamlessly with Rake, and uses familiar
|
11
|
+
and standard tools like ssh and rsync.
|
12
|
+
|
13
|
+
Impale your application on the heartless spike of the Deployer.
|
14
|
+
|
15
|
+
== FEATURES/PROBLEMS
|
16
|
+
|
17
|
+
* Full deployment automation stack.
|
18
|
+
* Turnkey deployment for mongrel+apache+svn.
|
19
|
+
* Supports single server deployment with just 3 variables defined.
|
20
|
+
* Built on rake. Easy. Engine is small.
|
21
|
+
* Very few dependencies. All simple.
|
22
|
+
* Uses ssh with your ssh settings already in place.
|
23
|
+
* Uses rsync for efficient transfers.
|
24
|
+
* Run remote commands on one or more servers.
|
25
|
+
* Mix and match local and remote tasks.
|
26
|
+
* Compatible with all of your tab completion shell script rake-tastic goodness.
|
27
|
+
* Ships with tests that actually pass in 0.028 seconds!
|
28
|
+
* Does NOT support Windows right now (we think). Coming soon in 1.2.
|
29
|
+
|
30
|
+
== SYNOPSIS
|
31
|
+
|
32
|
+
% rake vlad:setup # first time only
|
33
|
+
% rake vlad:update
|
34
|
+
% rake vlad:migrate # optional
|
35
|
+
% rake vlad:start
|
36
|
+
|
37
|
+
== REQUIREMENTS
|
38
|
+
|
39
|
+
* Rake
|
40
|
+
* Hoe
|
41
|
+
* Rubyforge
|
42
|
+
* open4
|
43
|
+
|
44
|
+
== INSTALL
|
45
|
+
|
46
|
+
* sudo gem install vlad
|
47
|
+
|
48
|
+
== SPECIAL THANKS
|
49
|
+
|
50
|
+
* First, of course, to Capistrano. For coming up with the idea and
|
51
|
+
providing a lot of meat for the recipes.
|
52
|
+
* Scott Baron for coming up with one of the best project names evar.
|
53
|
+
* Bradley Taylor for giving us permission to use RailsMachine recipes sans-LGPL.
|
54
|
+
|
55
|
+
== LICENSE
|
56
|
+
|
57
|
+
(The MIT License)
|
58
|
+
|
59
|
+
Copyright (c) 2007-2009 Ryan Davis and the rest of the Ruby Hit Squad
|
60
|
+
|
61
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
62
|
+
a copy of this software and associated documentation files (the
|
63
|
+
'Software'), to deal in the Software without restriction, including
|
64
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
65
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
66
|
+
permit persons to whom the Software is furnished to do so, subject to
|
67
|
+
the following conditions:
|
68
|
+
|
69
|
+
The above copyright notice and this permission notice shall be
|
70
|
+
included in all copies or substantial portions of the Software.
|
71
|
+
|
72
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
73
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
74
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
75
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
76
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
77
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
78
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/Rakefile
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
# -*- ruby -*-
|
2
|
+
|
3
|
+
require 'rubygems'
|
4
|
+
require 'hoe'
|
5
|
+
|
6
|
+
Hoe.plugin :seattlerb
|
7
|
+
|
8
|
+
Hoe.add_include_dirs "../../rake-remote_task/dev/lib"
|
9
|
+
|
10
|
+
Hoe.spec 'vlad' do
|
11
|
+
self.rubyforge_name = 'hitsquad'
|
12
|
+
|
13
|
+
developer 'Ryan Davis', 'ryand-ruby@zenspider.com'
|
14
|
+
developer 'Eric Hodel', 'drbrain@segment7.net'
|
15
|
+
developer 'Wilson Bilkovich', 'wilson@supremetyrant.com'
|
16
|
+
|
17
|
+
extra_deps << ['rake', '~> 0.8.0']
|
18
|
+
extra_deps << ['rake-remote_task', '~> 2.0']
|
19
|
+
extra_deps << ['open4', '~> 0.9.0']
|
20
|
+
|
21
|
+
# TODO: remove 1.9
|
22
|
+
multiruby_skip << "1.9" << "rubinius"
|
23
|
+
end
|
24
|
+
|
25
|
+
desc "quick little hack to see what the state of the nation looks like"
|
26
|
+
task :debug do
|
27
|
+
$: << 'lib'
|
28
|
+
require 'vlad'
|
29
|
+
Vlad.load :config => "lib/vlad/subversion.rb"
|
30
|
+
set :repository, "repository path"
|
31
|
+
set :deploy_to, "deploy path"
|
32
|
+
set :domain, "server domain"
|
33
|
+
|
34
|
+
Rake::Task['vlad:debug'].invoke
|
35
|
+
end
|
36
|
+
|
37
|
+
# vim: syntax=ruby
|
data/considerations.txt
ADDED
@@ -0,0 +1,91 @@
|
|
1
|
+
* might we want per connection values?
|
2
|
+
|
3
|
+
* :except => {:no_release => true}
|
4
|
+
|
5
|
+
It is common to configure tasks to 'announce' deployments in IRC, Campfire,
|
6
|
+
etc. If you have 6 app servers, you don't want to see 6 announcements. In
|
7
|
+
Capistrano, this is handled via the :no_release => true flag. Various tasks
|
8
|
+
only execute on the 'release' servers.
|
9
|
+
|
10
|
+
An easier way to meet this would be to introduce a :release role in the
|
11
|
+
default setup
|
12
|
+
|
13
|
+
role :release, "app1.example.com"
|
14
|
+
|
15
|
+
remote_task :announce_in_irc, :roles => :release ...
|
16
|
+
|
17
|
+
Drawback: Yet another thing to change when you migrate a project from cap to
|
18
|
+
vlad
|
19
|
+
|
20
|
+
* 'dynamic deployments'
|
21
|
+
|
22
|
+
role :app, "app1.example.com"
|
23
|
+
role :app, "app2.example.com"
|
24
|
+
|
25
|
+
Let's say that app1 and app2 need slightly different monit configurations.
|
26
|
+
|
27
|
+
In Capistrano, you might approach this by making two additional roles, and
|
28
|
+
splitting your 'push a monit config' task into two. This sucks.
|
29
|
+
|
30
|
+
Vlad makes the 'execution context' of a task available. In Vlad, you would:
|
31
|
+
|
32
|
+
remote_task :update_monit, :roles => :app
|
33
|
+
rsync "templates/#{target_host}.monitrc", "/etc/monitrc"
|
34
|
+
end
|
35
|
+
|
36
|
+
* fine-grained tasks
|
37
|
+
|
38
|
+
remote_task :update
|
39
|
+
remote_task :symlink
|
40
|
+
remote_task :migrate
|
41
|
+
remote_task :deploy => [:update, :symlink, :migrate, :restart]
|
42
|
+
|
43
|
+
Let's assume that this is a multi-server config with shared deploy path.
|
44
|
+
The user wants to do only a single checkout. If we make "update" be one big
|
45
|
+
task body that includes the update, symlink, and migrate steps,
|
46
|
+
it is difficult for the user to override the roles for the particular steps
|
47
|
+
they need to change.
|
48
|
+
|
49
|
+
If we break these into separate tasks, they can say:
|
50
|
+
|
51
|
+
Rake::Task["migrate"].options[:roles] = :master_db
|
52
|
+
|
53
|
+
and the migrations will only run on the master db
|
54
|
+
|
55
|
+
* sudo / via how? and if we call it via I will stab ppl. "user" is sufficient.
|
56
|
+
|
57
|
+
* handling 'use_sudo'
|
58
|
+
|
59
|
+
1. Check for this inside the 'run' command, and preface the command
|
60
|
+
with 'sudo' if necessary
|
61
|
+
|
62
|
+
2. Default this to 'false' in the reset method, and check for it
|
63
|
+
in the default tasks that we provide:
|
64
|
+
if use_sudo then
|
65
|
+
sudo "blah"
|
66
|
+
else
|
67
|
+
run "blah"
|
68
|
+
end
|
69
|
+
|
70
|
+
Option 2 has fewer moving parts, but clutters up the tasks that care about
|
71
|
+
this.
|
72
|
+
|
73
|
+
* Dependencies
|
74
|
+
|
75
|
+
Task dependencies aren't settable when creating a Rake::RemoteTask.
|
76
|
+
|
77
|
+
* Apache configuration
|
78
|
+
|
79
|
+
Pull in railsmachine/rails/recipes/apache.rb's apache configuration. Needs
|
80
|
+
erb to work.
|
81
|
+
|
82
|
+
* I really like tasks with naming <cmd>_<role> (eg setup_app,
|
83
|
+
start_web). We could easily make the front end remote_task command
|
84
|
+
look for such a convention and apply the :role => x automatically.
|
85
|
+
|
86
|
+
* from bousquet: get a couple of server environment recipes that prepare your
|
87
|
+
machine that would be the golden ticket:
|
88
|
+
|
89
|
+
rake vlad:prepare TYPE=accelerator | ubuntu | osx | osxserver | site5 | ...
|
90
|
+
|
91
|
+
and have people maintaining those setups who depend on them
|