Where do you put your app-config-files when deploying rails with capistrano and svn

后端 未结 2 2148
悲&欢浪女
悲&欢浪女 2021-02-09 09:24

I have two config-files

/app/config/database.yml

and

/app/config/userconfig.yml

i don\'t want to put the data

2条回答
  •  甜味超标
    2021-02-09 10:24

    You should place your config files in

    /path/to/deployed_app/shared
    

    Then in a capistrano task, sym link to those files:

    namespace :deploy do
      task :symlink_shared do
        run "ln -s #{shared_path}/database.yml #{release_path}/config/"
      end
    end
    
    before "deploy:restart", "deploy:symlink_shared"
    

提交回复
热议问题