No Description https://cryptcheck.fr/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

puma.rb 508B

12345678910111213141516171819202122232425262728
  1. threads_count = ENV.fetch 'RAILS_MAX_THREADS', 5
  2. threads threads_count, threads_count
  3. env = ENV.fetch 'RAILS_ENV', 'development'
  4. environment env
  5. unless Rails.root
  6. module Rails
  7. ROOT = Dir.pwd
  8. def self.root
  9. ROOT
  10. end
  11. end
  12. end
  13. if env == 'production'
  14. workers 4
  15. listen = ENV.fetch('LISTEN') { 'unix://' + File.join(Rails.root, 'tmp/sockets/puma.sock') }
  16. bind listen
  17. else
  18. listen = ENV.fetch('PORT') { 3001 }
  19. port listen
  20. end
  21. pidfile File.join Rails.root, 'tmp/pids/puma.pid'
  22. plugin :tmp_restart