rsm 0.1.8 → 0.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.8
1
+ 0.1.9
data/bin/rsm CHANGED
File without changes
@@ -33,7 +33,7 @@ module Rsm
33
33
 
34
34
  def thin_config
35
35
  inside "." do
36
- run_ruby_binary "thin config -C config/thin.yml -S tmp/sockets/thin.sock -s #{options[:worker_processes]} -e #{options[:environment]}"
36
+ run_with_bundler "thin config -C config/thin.yml -S tmp/sockets/thin.sock -s #{options[:worker_processes]} -e #{options[:environment]}"
37
37
  end
38
38
  end
39
39
  remove_task :thin_config
@@ -3,7 +3,7 @@ module Rsm
3
3
  class Stop < Rsm::Base
4
4
 
5
5
  def thin_stop
6
- run_ruby_binary "thin stop -C #{application_root}/config/thin.yml"
6
+ run_with_bundler "thin stop -C #{application_root}/config/thin.yml"
7
7
  end
8
8
 
9
9
  end
@@ -4,7 +4,7 @@ module Rsm
4
4
 
5
5
  def unicorn_rails
6
6
  inside "." do
7
- run "kill $(cat tmp/pids/unicorn.pid)"
7
+ run "kill $(cat tmp/pids/unicorn.#{options[:environment]}.pid)"
8
8
  end
9
9
  end
10
10
 
@@ -8,6 +8,8 @@
8
8
  # See http://unicorn.bogomips.org/Unicorn/Configurator.html for complete
9
9
  # documentation.
10
10
 
11
+ environment = ENV['RACK_ENV']
12
+
11
13
  # Use at least one worker per core if you're on a dedicated server,
12
14
  # more will usually help for _short_ waits on databases/caches.
13
15
  worker_processes <%= worker_processes %>
@@ -25,20 +27,20 @@ working_directory "<%= application_root %>/" # available in 0.94.0+
25
27
 
26
28
  # listen on both a Unix domain socket and a TCP port,
27
29
  # we use a shorter backlog for quicker failover when busy
28
- listen "<%= application_root %>/tmp/sockets/unicorn.sock", :backlog => 64
30
+ listen "<%= application_root %>/tmp/sockets/unicorn.#{environment}.sock", :backlog => 64
29
31
  #listen "127.0.0.1:8080", :tcp_nopush => true
30
32
 
31
33
  # nuke workers after 30 seconds instead of 60 seconds (the default)
32
34
  timeout 30
33
35
 
34
36
  # feel free to point this anywhere accessible on the filesystem
35
- pid "<%= application_root %>/tmp/pids/unicorn.pid"
37
+ pid "<%= application_root %>/tmp/pids/unicorn.#{environment}.pid"
36
38
 
37
39
  # By default, the Unicorn logger will write to stderr.
38
40
  # Additionally, ome applications/frameworks log to stderr or stdout,
39
41
  # so prevent them from going to /dev/null when daemonized here:
40
- stderr_path "<%= application_root %>/log/unicorn.stderr.log"
41
- stdout_path "<%= application_root %>/log/unicorn.stdout.log"
42
+ stderr_path "<%= application_root %>/log/unicorn.#{environment}.stderr.log"
43
+ stdout_path "<%= application_root %>/log/unicorn.#{environment}.stdout.log"
42
44
 
43
45
  # combine REE with "preload_app true" for memory savings
44
46
  # http://rubyenterpriseedition.com/faq.html#adapt_apps_for_cow
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: rsm
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.1.8
5
+ version: 0.1.9
6
6
  platform: ruby
7
7
  authors:
8
8
  - Oleksandr Ulianytskyi