Move Few Steps to Deploy Ruby code on Server
The Followings steps help you the deploy your ruby code on server from your local environment. you need to have capistrano 2.2.0 and railsmachine 1.0.0 installed locally or upgraded version.
1) Need to install rails-machine.
c:\> gem install railsmachine
if you find any problem then directly download .gem file from http://rubyforge.org/frs/?group_id=1336&release_id=30415.
After downloading the gem file try this.
c:\> gem install railsmachine-1.0.1.gem
2)Install Capistrano with all dependancies
gem install -y capistrano
if you find any problem then download directly from http://www.capify.org/download.
3) Capify your application
c:> capify .
Now the deploy.rb file will created under
4) Configure Capistrano for Rails Machine
c:> railsmachine --apply-to . --name my_app --domain my_domain.com
5) Modify the deploy.rb as per your requirements(if any)
6) Deploy the Code
c:\
or,if you need to run migrations as well
c:\
Hi Hitesh,
ReplyDeleteI have followed the steps you have mentioned but getting error
svn: Connection closed unexpectedly
Details of error
* executing `deploy'
* executing `deploy:update'
** transaction: start
* executing `deploy:update_code'
svn: Connection closed unexpectedly
*** [deploy:update_code] rolling back
.....
.....
c:/ruby/lib/ruby/gems/1.8/gems/capistrano-2.1.0/lib/capistrano/recipes/deploy/scm/subversion.rb:58:in `query_revision': tried to run `svn info svn+ssh: ..............
from c:/ruby/lib/ruby/gems/1.8/gems/capistrano-2.1.0/lib/capistrano/recipes/deploy/scm/base.rb:35:in `send'.......
Could you please help me on this?
Hey ,
ReplyDeleteI have the same problem.
please let us know what I need to do ?
Thanks
You Need to modify config file of Subversion.
ReplyDeleteadd this line in the config file
ssh = plink.exe
or
ssh=plink.exe -i putty/private_key.ppk -l deploy -pw xxxxxx
this plink file is in your putty dir. you also require pageant which reads authentication from .ppk file.
-
cheers
It works,
ReplyDeleteThanks dude.