public
Rubygem
Description: Engine Yard specific capistrano recipes
Clone URL: git://github.com/engineyard/eycap.git
Search Repo:
Change the references to release_path to latest_release.

This allows for users to run the tasks independent of a deploy.
halorgium (author)
Mon May 12 15:10:11 -0700 2008
commit  3eb18fd346390eda2c3d966bbb04f925180f2e77
tree    c2ada33df18cc11f5d62db1e914d6eae1bb9bdd0
parent  c4543b9bb5f013d72556ce4e5876f4718a9f1c16
...
13
14
15
16
17
18
 
 
 
19
20
21
...
87
88
89
90
91
 
...
13
14
15
 
 
 
16
17
18
19
20
21
...
87
88
89
 
90
91
0
@@ -13,9 +13,9 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     desc "Link the database.yml and mongrel_cluster.yml files into the current release path."
0
     task :symlink_configs, :roles => :app, :except => {:no_release => true} do
0
       run <<-CMD
0
- cd #{release_path} &&
0
- ln -nfs #{shared_path}/config/database.yml #{release_path}/config/database.yml &&
0
- ln -nfs #{shared_path}/config/mongrel_cluster.yml #{release_path}/config/mongrel_cluster.yml
0
+ cd #{latest_release} &&
0
+ ln -nfs #{shared_path}/config/database.yml #{latest_release}/config/database.yml &&
0
+ ln -nfs #{shared_path}/config/mongrel_cluster.yml #{latest_release}/config/mongrel_cluster.yml
0
       CMD
0
     end
0
   
0
@@ -87,4 +87,4 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     end
0
   end
0
 
0
-end
0
\ No newline at end of file
0
+end
...
4
5
6
7
8
9
10
 
 
 
 
11
12
13
...
4
5
6
 
 
 
 
7
8
9
10
11
12
13
0
@@ -4,10 +4,10 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     desc "After update_code you want to symlink the index and ferret_server.yml file into place"
0
     task :symlink_configs, :roles => :app, :except => {:no_release => true} do
0
       run <<-CMD
0
- cd #{release_path} &&
0
- ln -nfs #{shared_path}/config/ferret_server.yml #{release_path}/config/ferret_server.yml &&
0
- if [ -d #{release_path}/index ]; then mv #{release_path}/index #{release_path}/index.bak; fi &&
0
- ln -nfs #{shared_path}/index #{release_path}/index
0
+ cd #{latest_release} &&
0
+ ln -nfs #{shared_path}/config/ferret_server.yml #{latest_release}/config/ferret_server.yml &&
0
+ if [ -d #{latest_release}/index ]; then mv #{latest_release}/index #{latest_release}/index.bak; fi &&
0
+ ln -nfs #{shared_path}/index #{latest_release}/index
0
       CMD
0
     end
0
     [:start,:stop,:restart].each do |op|
...
4
5
6
7
8
 
 
9
10
11
...
4
5
6
 
 
7
8
9
10
11
0
@@ -4,8 +4,8 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     desc "After update_code you want to symlink the juggernaut.yml file into place"
0
     task :symlink_configs, :roles => :app, :except => {:no_release => true} do
0
       run <<-CMD
0
- cd #{release_path} &&
0
- ln -nfs #{shared_path}/config/juggernaut.yml #{release_path}/config/juggernaut.yml
0
+ cd #{latest_release} &&
0
+ ln -nfs #{shared_path}/config/juggernaut.yml #{latest_release}/config/juggernaut.yml
0
       CMD
0
     end
0
     [:start,:stop,:restart].each do |op|
...
14
15
16
17
 
18
19
20
...
14
15
16
 
17
18
19
20
0
@@ -14,7 +14,7 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     end
0
     desc "Symlink the memcached.yml file into place if it exists"
0
     task :symlink_configs, :roles => :app, :only => {:memcached => true }, :except => { :no_release => true } do
0
- run "if [ -f #{shared_path}/config/memcached.yml ]; then ln -nfs #{shared_path}/config/memcached.yml #{release_path}/config/memcached.yml; fi"
0
+ run "if [ -f #{shared_path}/config/memcached.yml ]; then ln -nfs #{shared_path}/config/memcached.yml #{latest_release}/config/memcached.yml; fi"
0
     end
0
   end
0
 end
...
4
5
6
7
 
8
9
10
...
34
35
36
37
38
 
...
4
5
6
 
7
8
9
10
...
34
35
36
 
37
38
0
@@ -4,7 +4,7 @@ Capistrano::Configuration.instance(:must_exist).load do
0
     desc "After update_code you want to symlink the index and ferret_server.yml file into place"
0
     task :symlink_configs, :roles => :app, :except => {:no_release => true} do
0
       run <<-CMD
0
- cd #{release_path} && ln -nfs #{shared_path}/config/solr.yml #{release_path}/config/solr.yml
0
+ cd #{latest_release} && ln -nfs #{shared_path}/config/solr.yml #{latest_release}/config/solr.yml
0
       CMD
0
     end
0
     
0
@@ -34,4 +34,4 @@ Capistrano::Configuration.instance(:must_exist).load do
0
       end
0
     end
0
   end
0
-end
0
\ No newline at end of file
0
+end
...
26
27
28
29
30
 
 
31
32
33
...
26
27
28
 
 
29
30
31
32
33
0
@@ -26,8 +26,8 @@ Capistrano::Configuration.instance(:must_exist).load do
0
 
0
     desc "Symlink the sphinx config file"
0
     task :symlink, :roles => :app, :only => {:sphinx => true}, :except => {:no_release => true} do
0
- run "if [ -d #{release_path}/config/ultrasphinx ]; then mv #{release_path}/config/ultrasphinx #{release_path}/config/ultrasphinx.bak; fi"
0
- run "ln -nfs #{shared_path}/config/ultrasphinx #{release_path}/config/ultrasphinx"
0
+ run "if [ -d #{latest_release}/config/ultrasphinx ]; then mv #{latest_release}/config/ultrasphinx #{latest_release}/config/ultrasphinx.bak; fi"
0
+ run "ln -nfs #{shared_path}/config/ultrasphinx #{latest_release}/config/ultrasphinx"
0
     end
0
   end
0
 

Comments

    No one has commented yet.