In application.rb, inside the class add:
Rails.application.routes.default_url_options[:host] = "load url that is appropriate for different environments in your app here"
Now you can go to the rails console:
> include Rails.application.routes.url_helpers
and call different url_helpers like this:
profile_url