# Relative paths are assumed to be in #{Rails.root}/config.
# Path to the template
path: templates/database.yml.erb
However, when I set up {root}\config\templates\database.yml.erb and started my rails app, I got this exception:
$ bundle exec rails s
Error rendering template: database
c:/bin/ruby/243/lib/ruby/gems/2.4.0/gems/consult-0.5.0/lib/consult/template.rb:18:in `read': No such file or directory @ rb_sysopen - C:/Users/aharper/workspace/consult-rails-test/crt-app/templates/database.yml.erb (Errno::ENOENT)
Note that it's not looking in /config, it's looking in the app root folder. This is confirmed by moving the templates directory to the app root and starting the app... this exception does not occur.
The readme's example consult.yml says:
However, when I set up
{root}\config\templates\database.yml.erb
and started my rails app, I got this exception:Note that it's not looking in
/config
, it's looking in the app root folder. This is confirmed by moving the templates directory to the app root and starting the app... this exception does not occur.