1 set :application, "lyrix"
2 set :repository, "git://repo.or.cz/lyrix.git"
3 set :user, "jcmcarpetcare"
5 # If you aren't deploying to /u/apps/#{application} on the target
6 # servers (which is the default), you can specify the actual location
7 # via the :deploy_to variable:
8 set :deploy_to, "/home/#{user}/sites/#{application}"
10 # If you aren't using Subversion to manage your source code, specify
13 set :scm_command, "~/bin/git"
14 set :git_dir, "#{shared_path}/git"
17 #set :deploy_via, :copy
19 role :app, "jcmcarpetcare.com"
20 role :web, "jcmcarpetcare.com"
21 role :db, "jcmcarpetcare.com", :primary => true
25 before "deploy:setup", :db
26 after "deploy:update_code", "db:symlink"
29 desc "Create database yaml in shared path"
31 db_config = ERB.new <<-EOF
39 database: #{application}_dev
43 database: #{application}_test
47 database: #{application}_prod
51 run "mkdir -p #{shared_path}/config"
52 put db_config.result, "#{shared_path}/config/database.yml"
55 desc "Make symlink for database yaml"
57 run "ln -nfs #{shared_path}/config/database.yml #{release_path}/config/database.yml"
63 Sets up the git repository clones to :git_dir on the app servers.
65 task :git_clone, :except => { :no_release => true } do