Sha256: 4344d178299a33335e0b8017cb13fa764196353ca1a2354cd21f8c3e90e3da84
Contents?: true
Size: 744 Bytes
Versions: 2
Compression:
Stored size: 744 Bytes
Contents
# Rails recipes namespace :rails do desc <<-DESC Create database yaml in shared path. db_name: Database name (rails). set :db_name, "app_db_name" db_user: Database user (rails). set :db_user, "app_db_user" db_pass: Database password (rails). set :db_pass, "the_password" DESC task :setup do # Settings fetch(:db_name) fetch(:db_user) fetch(:db_pass) run "mkdir -p #{shared_path}/config" put template.load("rails/database.yml.erb"), "#{shared_path}/config/database.yml" end desc "Make symlink for database yaml" task :update_code do run "ln -nfs #{shared_path}/config/database.yml #{release_path}/config/database.yml" end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
capitate-0.1.8 | lib/recipes/rails.rb |
capitate-0.1.9 | lib/recipes/rails.rb |