#!/bin/bash --login # Start delayed job using rake # Delayed_Job worker <%= fetch(:tmp_worker_number) %> running on <%= fetch(:application) %> running as <%= fetch(:user) %> # Redirect stderr so everything ends up in the log file exec 2>&1 # Announce start echo "<%= "User: #{fetch(:user)} Application: #{fetch(:application)} Service: #{fetch(:tmp_delayed_job_runit_service_name)}" %> starting..." # Change path to current path cd '<%= current_path %>' # Start delayed job RAILS_ENV=<%= environment %> exec <%= fetch(:delayed_job_bin) %>