I am running into a bizarre problem. My rails console is not loading parts of my rails environment, but only in production. In development it works fine.
:~/production_code/current$ RAILS_ENV=production rbenv exec rails c
Running via Spring preloader in process 26218
Loading production environment (Rails 5.2.1)
ActiveRecord::Base.connection.tables
=> ["schema_migrations", "ar_internal_metadata", "markets", "delayed_jobs", "users"]
irb(main):004:0> Market
Traceback (most recent call last):
1: from (irb):4
NameError (uninitialized constant Market)
Did you mean? Marcel
irb(main):005:0>
I also does not understand reset! and RAILS_ROOT is undefined.
I'm really puzzled as to what's going on and not sure where to investigate from here.