def default_run
setup_logging
if @options[:attach]
self.attach
end
if @options[:port]
God.port = @options[:port]
end
if @options[:events]
God::EventHandler.load
end
if @options[:log_level]
God.log_level = @options[:log_level]
else
God.log_level = @options[:daemonize] ? :warn : :info
end
if @options[:config]
if !@options[:config].include?('*') && !File.exist?(@options[:config])
abort "File not found: #{@options[:config]}"
end
God::EventHandler.start if God::EventHandler.loaded?
load_config @options[:config]
end
setup_logging
end