title: Different Rails route if IP not in list?
body: <p>I have a Rails 3.2.2 application which is a simple company intranet, however although there isn't any private information on there it's probably best if it was fairly secure from the outside world. </p>
  
  <p>We do however have people working from home on fairly regular occasions that don't have a VPN setup. </p>
  
  <p>Currently I have a firewall rule that blocks everyone except a list of our teams/branches static IP addresses. The problem with this is when a team member visits the site from home the site never loads because the firewall rejects them. What I would like to do is serve a simple page within the application explaining why they don't have "full" access. </p>
  
  <p>The firewall is serving multiple applications, so I can't put the access denied page on there </p>
  
  <p>I have read a few questions on SO such as <a href="https://stackoverflow.com/questions/3887943/ip-address-in-rails">Get real IP address in local Rails development environment</a> which show how to get their IP address, but I'm unsure how to alter a default route based on that. </p>