diff --git a/Capfile b/Capfile index da709e35..6b226745 100644 --- a/Capfile +++ b/Capfile @@ -17,7 +17,7 @@ require 'capistrano/deploy' require 'capistrano/rvm' # require 'capistrano/rbenv' # require 'capistrano/chruby' -require 'capistrano-bundler' +require 'capistrano/bundler' require 'capistrano/rails/assets' # require 'capistrano/rails/migrations' require 'capistrano/puma' diff --git a/config/deploy.rb b/config/deploy.rb index c69ad356..89fe7d6c 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -32,7 +32,7 @@ set :deploy_to, '/var/www/mozo.bar' # set :linked_files, %w{config/database.yml} # Default value for linked_dirs is [] -set :linked_dirs, %w{log tmp/pids tmp/cache tmp/sockets vendor/bundle public/system} +set :linked_dirs, %w{log tmp/pids tmp/cache tmp/sockets vendor/bundle public/system public/assets} # Default value for default_env is {} # set :default_env, { path: "/opt/ruby/bin:$PATH" } @@ -112,13 +112,13 @@ namespace :deploy do end end - desc 'Set config/puma.rb-symlink for upstart' - task :puma_config do - on roles(:app) do - execute "ln -s #{shared_path}/puma.rb #{release_path}/config/puma.rb" - end - end - after :finishing, :puma_config + #desc 'Set config/puma.rb-symlink for upstart' + #task :puma_config do + #on roles(:app) do + #execute "ln -sf #{shared_path}/puma.rb #{release_path}/config/puma.rb" + #end + #end + #after :finishing, :puma_config after :publishing, :restart do #deploy.update_remote_cache diff --git a/config/puma.rb b/config/puma.rb deleted file mode 100644 index 0ffefd1a..00000000 --- a/config/puma.rb +++ /dev/null @@ -1,29 +0,0 @@ -# Change to match your CPU core count -workers 2 - -# Min and Max threads per worker -threads 1, 6 - -app_dir = File.expand_path("../..", __FILE__) -shared_dir = "#{app_dir}/shared" - -# Default to production -rails_env = ENV['RAILS_ENV'] || "production" -environment rails_env - -# Set up socket location -bind "unix://#{shared_dir}/sockets/puma.sock" - -# Logging -stdout_redirect "#{shared_dir}/log/puma.stdout.log", "#{shared_dir}/log/puma.stderr.log", true - -# Set master PID and state locations -pidfile "#{shared_dir}/pids/puma.pid" -state_path "#{shared_dir}/pids/puma.state" -activate_control_app - -#on_worker_boot do - #require "active_record" - #ActiveRecord::Base.connection.disconnect! rescue ActiveRecord::ConnectionNotEstablished - #ActiveRecord::Base.establish_connection(YAML.load_file("#{app_dir}/config/database.yml")[rails_env]) -#end