Skip to content
soffolk edited this page Nov 10, 2013 · 1 revision

use unicorn as web server

Below is an simple example for unicorn configure:wiki

# set path to app that will be used to configure unicorn,
# note the trailing slash in this example
@dir = "/home/deploy/rails_apps/API-mock-server/"

worker_processes 2
working_directory @dir

timeout 30

# Specify path to socket unicorn listens to,
# we will use this in our nginx.conf later
listen "#{@dir}tmp/sockets/unicorn.sock", :backlog => 64

# Set process id path
pid "#{@dir}tmp/pids/unicorn.pid"

# Set log file paths
stderr_path "#{@dir}log/unicorn.stderr.log"
stdout_path "#{@dir}log/unicorn.stdout.log"
Clone this wiki locally