Files
discourse/bin/rails
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

19 lines
478 B
Ruby
Raw Normal View History

2014-02-06 11:15:00 -08:00
#!/usr/bin/env ruby
# frozen_string_literal: true
2018-08-07 17:13:20 +10:00
if !ENV["RAILS_ENV"] && (ARGV[0] == "s" || ARGV[0] == "server") && Process.respond_to?(:fork)
2018-08-15 10:25:00 +10:00
ENV["UNICORN_PORT"] ||= "3000"
if ARGV[1] == "-p" && (port = ARGV[2].to_i) > 0
ENV["UNICORN_PORT"] = port.to_s
end
2018-08-14 08:49:57 +10:00
ENV["RAILS_LOGS_STDOUT"] ||= "1"
2018-08-07 17:13:20 +10:00
exec File.expand_path("unicorn", __dir__)
end
APP_PATH = File.expand_path('../config/application', __dir__)
2015-04-16 16:15:04 +10:00
require_relative '../config/boot'
require 'rails/commands'