Created
October 2, 2015 08:53
-
-
Save lukemorton/e443c93df22ec7669a70 to your computer and use it in GitHub Desktop.
For rails 4.2 projects served from inside vagrant
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) | |
require 'bundler/setup' # Set up gems listed in the Gemfile. | |
# Override default IP binding so that we can work inside vagrant!! | |
# | |
require 'rails/commands/server' | |
module Rails | |
class Server | |
alias :default_options_alias :default_options | |
def default_options | |
default_options_alias.merge!(:Host => '0.0.0.0') | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment