I have a file named home.html inside the /public directory of a Rails 4 app.
In the routes.rb file I have these lines:
Rails.application.routes.draw do
get '/', :to => redirect('/home.html')
end
However I still get a 404:
2014-10-17T06:45:35.541582+00:00 heroku[router]: at=info method=GET path="/" host=app.herokuapp.com request_id=e66b6e76-bdf5-43e3-ba60-5c330ef96c11 fwd="54.242.93.32" dyno=web.1 connect=2ms service=1062ms status=301 bytes=460
2014-10-17T06:45:35.555594+00:00 heroku[router]: at=info method=GET path="/home.html" host=app.herokuapp.com request_id=a7bc7dbd-9647-4727-80dc-c3aaaeafa0d0 fwd="54.242.93.32" dyno=web.1 connect=2ms service=7ms status=404 bytes=1829
Anybody know how to fix this? (Without resorting to using controllers.)
Edit
Discovered this is the right syntax for routes.rb: get '/', to: redirect('/home.html')
Still getting 404 errors on heroku though.