X-Git-Url: https://git.njae.me.uk/?a=blobdiff_plain;f=config%2Fdeploy.sample.rb;fp=config%2Fdeploy.sample.rb;h=e3ad447c62d9669c14db3aa022e66e1547787381;hb=b24d0db11b8a9b6815c0b235b77e557ea5993e35;hp=0000000000000000000000000000000000000000;hpb=42222e338636dceaf6db289fa81b62038af145ee;p=feedcatcher.git diff --git a/config/deploy.sample.rb b/config/deploy.sample.rb new file mode 100644 index 0000000..e3ad447 --- /dev/null +++ b/config/deploy.sample.rb @@ -0,0 +1,42 @@ +set :application, "feedcatcher" +set :repository, "http://server.example.com/svn/#{application}/branches/stable" + +# If you aren't deploying to /u/apps/#{application} on the target +# servers (which is the default), you can specify the actual location +# via the :deploy_to variable: +set :deploy_to, "/var/www/feedcatcher/" + +# If you aren't using Subversion to manage your source code, specify +# your SCM below: +set :scm, :subversion +set :scm_username, 'user' + +role :app, "feedcatcher.example.com" +role :web, "feedcatcher.example.com" +role :db, "feedcatcher.example.com", :primary => true + +# Have the spinner/spawner/reaper processes run as the default user +set :runner, nil + +# Copy the database.yml file across, as it's not kept in the SVN repository +after "deploy:update_code" , :configure_database +desc "copy database.yml into the current release path" +task :configure_database, :roles => :app do + db_config = "#{deploy_to}/config/database.yml" + run "cp #{db_config} #{release_path}/config/database.yml" +end + + +namespace :deploy do + task :start, :roles => :app do + end + + task :stop, :roles => :app do + end + + desc "Restart Application" + task :restart, :roles => :app do + run "touch #{release_path}/tmp/restart.txt" + end + +end