how to modify some configuration settings in the osm web site ?
frederik at remote.org
Tue Nov 29 12:16:23 UTC 2016
you would normally put a proper web server (Apache, Nginx) in front
of everything, so the proper web server listens on port 80 or 443 and
can then decide what to do, e.g. it could serve tiles *and* forward some
requests to rails (or perhaps use a module that allows the web server to
execute a rails app directly).
That would fix your issues 1, 2, 3, 4.
> 6) How to configure the web site to use the test database (osm_test) ?
> May be setting a linux variable RAILS_ENV to test (to be read by
> preinitializer.rb file) ?
In Ruby applications the test database is usually reserved for automated
testing, and its contents can be discarded in the course of running
tests, so you would not normally use it (you would use dev and
production). If you use a web server module you can control which mode
the application is in (and hence which database is used) from a config
option in your web server config, or of course you could use a
commandline option when starting up rails.
> 7) Why are only 2 databases created by the "bundle exec rake db:create"
> command instead of the 3 described in example.database.yml file ?
Unsure, frankly I am surprised that it even creates 2, I thought it
would only create the one matching your RAILS_ENV.
Frederik Ramm ## eMail frederik at remote.org ## N49°00'09" E008°23'33"
More information about the rails-dev