Blog

rails deployment symlink

rails deployment symlink

Today I developed at a project, where I need an extra symlink after each new deployment. I do the deployment with capistrano. Here is my code snippet:

task :symlink_documents do
  run "mkdir -p #{release_path}/non-public/system"
  run "ln -nfs #{shared_path}/system/documents #{release_path}/non-public/system/documents"
end

after "deploy:update_code", :symlink_documents

And the symlink will be created after every new deployment.

31.05.2011
Matthias Frick
Ruby on Rails
0 Kommentare

Über den Autor

Matthias Frick
Matthias Frick, MSc.

Er ist ein langjähriger Ruby-on-Rails Entwickler und leitet das Unternehmen Frick-Web.

0 Kommentare zu "rails deployment symlink"

Kommentar verfassen