Latest Items
- devise_invitable: Confirm after set password
Continue reading...class User < ActiveRecord::Basedevise :invitable, :database_authenticatable, :registerable, :recoverable,:rememberable, :confirmable, :validatable, :encryptable# ...# devise confirm! method overridendef confirm!welcome_messagesuperend# devise_invitable accept_invitation! method overridendef accept_invitation!self.confirm!superend# devise_invitable invite! method overridendef invite!... - Clever use of Dropbox + GITClever use of Dropbox + GIT: http://pivotallabs.com/users/ken/blog/articles/1637-dropbox-git-designer-luv
- Capistrano: Managing an uploads folderI just found a useful Capistrano recipe for keeping user generated content (a.k.a. uploads) persistent between deployments:
http://www.simonecarletti.com/blog/2009/02/capistrano-uploads-folder/
EDIT: I would like to extend the script to many folders. Any idea? - File: benoror@macmini:~/simpleapp/config/deploy.rb
Continue reading...default_run_options[:pty] = trueset :user, 'benoror'set :domain, 'simpleapp.com'set :application, 'simpleapp'# the rest should be goodset :repository, "#{user}@#{domain}:#{application}.git"set :deploy_to, "/home/#{user}/#{domain}"set :deploy_via, :remote_cacheset :scm, 'git'set :branch, 'master'#set :git_shallow_clone, 1set :scm_verbose, trueset :use_sudo, falseserver domain, :app, :web, :db, :primary => trueafter "deploy:restart", "deploy:search_index"... - Capistrano as my default deployment toolIn the last post (a whiiile ago) I described my Git workflow to deploy my production server. One of the drawbacks was that everytime I pushed changes to the main repo I had to manually log in my Dreamhost shared host via SSH and then: 1) pull changes, 2) migrate database schema, 3) rebuild sphinx index, 4) restart passenger server. I wrote a bash script to get the job done, but it was prone to errors and not elegant, so I decided to give Capistrano a try.After reading the Getting Started and From the Beginning guides I got a good idea of what to do next. Basically my setup is as follows:File: benoror@macmini:~/simpleapp/CapfileFile: benoror@macmini:~/simpleapp/config/deploy.rbSo now when I make changes to the code I simply follow this workflow in my local machine:git add . && git commit -a -m "Commit Msg" && git pushcap deploycap deploy:migrateThat's it!The next step is to setup a staging server, until then see you soon ...
Generated at Sep 21, 2026, 9:44 PM