Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-4314

Error when trying to generate mongoid.yml

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 12_01_17
    • Affects Version/s: 6.0.0
    • Component/s: None
    • None

      I'm trying to use the new mongoid version 6.0.0.rc0 with a rails 5 app.

      There is no documentation here, and I can't find docs for version 6.x on how to remove all the Active record stuff from my rails app so that I can generate a mongoid.yml file.

      I've removed my database.yml file and tried to run:

      $ rails g mongoid:config

      and I get the error:

      /Users/tomcaflisch/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/application/configuration.rb:143:in `database_configuration': Cannot load `Rails.application.database_configuration`:
      Could not load database configuration. No such file - ["config/database.yml"] (RuntimeError)

      How can I get past this error? I'm assuming I need to change some active record references somewhere?

            Assignee:
            emily.stolfo Emily Stolfo
            Reporter:
            toymachiner62 Tom Caflisch
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: