Db:migrate from within controller

Hi all,

Anyone tried calling RAILS_ENV=production bundle exec rake db:migrate from
within a controller? It is not working for me and i see

/usr/lib/ruby/vendor_ruby/rails/railtie.rb:120: warning: already
initialized constant Rails::Railtie::ABSTRACT_RAILTIES
/usr/share/moy/vendor/ruby/2.3.0/gems/railties-4.1.14.2/lib/rails/railtie.rb:119:
warning: previous definition of ABSTRACT_RAILTIES was here
rake aborted!
LoadError: cannot load such file – fog/ovirt

in the production.log

Any ideas?

Thanks