#!/usr/bin/env ruby require 'spoon' file_actions = Spoon::FileActions.new file_actions.close(1) file_actions.open(1, "log/development.log", File::WRONLY | File::TRUNC | File::CREAT, 0600) spawn_attr = Spoon::SpawnAttributes.new pid = Spoon.posix_spawn('jubilee', file_actions, spawn_attr, *ARGV) open("tmp/jubilee.pid"){|f| f.write(pid) }