Skip to content

Instantly share code, notes, and snippets.

app_name = "ldl-website"
root = "/var/www/#{app_name}/current"
pid "#{root}/tmp/pids/unicorn.pid"
stderr_path "#{root}/log/unicorn.error.log"
stdout_path "#{root}/log/unicorn.access.log"
listen "/tmp/unicorn.#{app_name}.sock", :backlog => 2048
preload_app true
app_name = "ldl-website"
root = "/var/www/#{app_name}/current"
pid "#{root}/tmp/pids/unicorn.pid"
stderr_path "#{root}/log/unicorn.error.log"
stdout_path "#{root}/log/unicorn.access.log"
listen "/tmp/unicorn.#{app_name}.sock", :backlog => 2048
preload_app true
#!/bin/sh
### BEGIN INIT INFO
# Provides: unicorn
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Manage unicorn server
# Description: Start, stop, restart unicorn server for a specific application.
### END INIT INFO