search for: current_path

Displaying 20 results from an estimated 46 matches for "current_path".

2006 Aug 24
5
Unable to start with Capistrano...
...d success with this? Here are my deploy tasks: desc ''Start backgroundrb server (default values)'' task :start_backgroundrb do puts "Starting BackgrounDRb" #--- assumes the backgroundrb.yml is set up for production run "export RAILS_ENV=production && #{current_path}/script/backgroundrb/start -d" end desc ''Stop backgroundrb server (default values)'' task :stop_backgroundrb do puts "Stopping BackgrounDRb" begin run "#{current_path}/script/backgroundrb/stop" rescue end end I''m no doubt missing some...
2008 Mar 05
4
Vlad the Deployer??
I''ve been playing around with Vlad the deployer, and quite like it. However, has anyone used it to stop/start background rb processes via the ./script/backgroundrb script? Eric ----------------------------------------------------- Eric Pugh | Principal | OpenSource Connections, LLC | 434.466.1467 | http://www.opensourceconnections.com
2006 Jun 16
15
Mongrel_rails restart and sudo
Sorry for the newbie question but I''m stumped: I have an app that requires sudo to run mongrel_rails. For my capistrano recipe is do it like this: sudo "mongrel_rails start -e production -p #{application_port} -d -c #{current_path}" Which works famously. Now I have tried several things for my restart task. Here they are: sudo "cd #{current_path} && sudo mongrel_rails restart" That doesn''t work. For some reason the "cd..." command does not work. I''m assuming that is so...
2011 Mar 21
1
Getting user session object in cucumber
...id credentials$/ do fill_in(''Email'', :with=>"john_rennie-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org") fill_in(''Password'', :with=>"neova123") click_button("Login") end Then /^user should be on project (.+)$/ do |page_name| current_path = URI.parse(current_url).path if current_path.respond_to? :should current_path.should == path_to(page_name) else assert_equal path_to(page_name), current_path end end When /^user create a project with name "([^"]*)"$/ do |project_name| visit new_project_path fill_i...
2009 Jul 31
6
Background daemon
...lse end while($running) do Notifier.deliver_report_daily #ActiveRecord::Base.logger.info "This daemon is still running at #{Time.now}.\n" sleep 86400 end ########### # deploy.rb ############ desc "Stop daemons before deploying" task :before_deploy do run "#{current_path}/script/daemons stop" end desc "Start daemons after deploying" task :after_deploy do run "#{current_path}/script/daemons start" end -- Posted via http://www.ruby-forum.com/.
2011 Oct 16
2
current_path?
What''s the best way to retrieve the current path? (i.e. /posts/1) -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to
2006 Apr 03
2
Capistrano - how do I set up the database config?
...d put database.yml in it. After I update the code, I want to link the app''s database.yml file to the shared config. So I added this task desc ''Copy the database config'' task :after_update_code, :roles => :app do run "ln -s #{shared_path}/config/database.yml #{current_path}/config/database.yml" end Unfortunately that doesnt work, because update_code is in a transaction, so current_path points to the app that''s currently running, rather than the most recently checked out code version. So I get the following error: * executing task after_update_code...
2007 Feb 05
3
Deploying to production with backgroundrb (capistrano)
...this is my basic setup i have 2 workers: lib/workers/mp3_worker.rb => takes a hash of params to downsample an mp3 lib/workers/flv_worker.rb => takes a has of arguments to compose a command line to convert a file into flv in my recipe config/deploy.rb i have 2 lines run "#{current_path}/script/backgroundrb stop" run "#{current_path}/script/backgroundrb start" that should stop the server and restart it. after the deploy, i have started sshing in tot he box and running script/backgroundrb console and checking the loaded_worker_classes about 50% of the time,...
2007 Feb 05
1
Deploying with capistrano issue. Resolution !
ok, i was wrong. the failure on deployment using capistrano is 100% using these commands ## Our Handlers desc "Restart BackgrounDrb" task :restart_uploader, :roles => :app do run "#{current_path}/script/backgroundrb stop" run "#{current_path}/script/backgroundrb start" end here is the console post deploy on the remote server ######## [current]$ script/backgroundrb console irb: warn: can''t alias jobs from irb_jobs. irb(#<BackgrounDRb::MiddleMan:0xb7b74088>)...
2005 Nov 07
5
Switchtower deployment
Hi, Has anyone experiences using SwitchTower (Windows) in a shared hosting environment (Textdrive)? I already patched the SwitchTower rake tasks (I don''t know if someone is interested on it), but i still experience some problems (not in the sudoers list, ...). Thank you for answer (and thank you to the textdrive guys, i never had a such fast support!) -- Jean-Etienne Durand
2006 May 25
5
Weird Capistrano problem
...s my spin script: #!/bin/bash /Web/Rails/Example/current/script/process/spinner \ -c ''/Web/Rails/Example/current/script/process/spawner -p 7000 -i 5'' \ -d And the deploy.rb task: desc "Start the spinner daemon" task :spinner, :roles => :app do run "#{current_path}/script/spin" end Pretty much the same as the Capistrano docs. Any help or suggestions would be greatly appreciated. -ch -- Posted via http://www.ruby-forum.com/.
2006 Apr 21
9
Capistrano, OS X
...rano to a host with a different path to ruby (which would be practially all of them:-) Here''s a fix. Add this "fix_hashbangs.rb" script to your script directory. Don''t forget to make it executable, and check it in to your Subversion repository. #!/usr/bin/env ruby current_path = ARGV[0] new_hashbang = ARGV[1] f_names = %w(dispatch.cgi dispatch.rb dispatch.fcgi) f_names.each do |name| puts `ls -al "#{current_path}/public/#{name}" ` File.open("#{current_path}/public/#{name}", "r+") do |f| f_contents = f.read f_contents.gsub!(/^#!.+...
2009 Feb 15
2
Execute cap deploy:migrations fails
...:deploy_via, :remote_cache set :scm, ''git'' set :branch, ''master'' set :git_shallow_clone, 1 set :scm_verbose, true set :use_sudo, false server domain, :app, :web role :db, domain, :primary => true namespace :deploy do task :restart do run "touch #{current_path}/tmp/restart.txt" end end I am guessing my path to my git repository is incorrect but I checked many ... many times and this is my path on my host. Any help would be greatly appreciated, thank you Olivier --~--~---------~--~----~------------~-------~--~----~ You received this message be...
2006 May 25
2
Capistrano only runs migration against production env?
All, Just read in the Capistrano manual about the Capistrano "migrate" task. There it says that: "By default, all this task does is change to the directory of your current release (as indicated by the current symlink), and run rake RAILS_ENV=production migrate. You can specify that it should run against the latest release (regardless of what the current release is) by setting
2011 Jul 13
1
Feature request: Determining source index of xapian-compact DatabaseError exception
...I've hacked the source a bit in a few areas (by using std::string name from chert_table.h) to emit *something* useful, eg in ChertTable::read_block(): string message = "Error reading block " + str(n) + ": "; message += strerror(errno); + message += " (current_path: " + name + ")"; throw Xapian::DatabaseError(message); } else if (bytes_read == 0) { string message = "Error reading block " + str(n) + ": got end of file"; + message += " (current_path: " + name + ")"; throw...
2011 May 22
1
How do you crop an image with carrierwave 'after the fact' in rails?
What I''d like to do is upload an image, then take the user to a new page where I will use Jcrop to let the user select the part of the image they want to crop, and then store that image. Essentially, I want to make it a 2-stage process. I know how to do the javascript part, and I understand the basic flow of how to create this functionality. However, I am not aware of the carrierwave
2006 Jul 31
1
Starting backgroundrb from rails and restarting with rails
Hi, I have my rails sites tricked out with capistrano, and backgroundrb, so I can easily use the ant tasks, but I would like to be able to start and stop backgroundrb from within rails. I have a few reasons for this: 1. Using fastcgi, backgroundrb would start under the apache user and the same mod_security context as apache, instead of my developer account which has many more privileges. 2.
2007 Apr 17
7
problem restarting mongrel_cluster outside RAILS_ROOT - patch and other option
Hey folks. Sorry for the SUPER long email but if you''ve been experiencing the same problems with restarting your mongrel cluster with Capistrano, then I have two solutions that have worked for me and I''m pretty sure will for you as well. THE PROBLEM I was having trouble restarting my clusters using Capistrano. I''ve seen this come up before on the mailing list and
2008 Jan 03
5
Start script not working when run via Rake
...I''m using the latest release (r300) and ''script/backgroundrb start'' works perfectly when executed on the server, but when put inside a Rake task, it doesn''t launch the worker processes. The Rake task is as follows: task :start_backgroundrb do run "cd #{current_path} && ./script/backgroundrb start" end When I run this task, the following files are created in the log directory: backgroundrb.pid backgroundrb_debug.log backgroundrb_server.log Observations: The process ID found in backgroundrb.pid doesn''t exist, backgroundrb_server.log i...
2008 May 05
2
Deploying to a staging server using Capistrano: how to start up BackgrounDRb?
...ronment." task :copy_mongrel_cluster_config do run "cp -f #{release_path}/config/deploy/staging/mongrel_cluster.yml #{release_path}/config/mongrel_cluster.yml" end desc "Start the backgroundrb server" task :start_backgroundrb , :roles => :app do run "cd #{current_path} && nohup ./script/backgroundrb start -- -r staging > #{current_path}/log/backgroundrb-cap.log 2>&1" end desc "Stop the backgroundrb server" task :stop_backgroundrb, :roles => :app do run "cd #{release_path} && ./script/backgroundrb -e stagin...