You can compile it rake assets:precompile
in dev m/c and then commit the public/assets folder to remote repo. So when the production server is started it will take the already precompiled assets from the assets folder. Make sure any js/css/image change you do, update the assets file accordingly.
Any gem mentioned in Gemfile has to be installed. In case you don't feel the need to use specific gems, remove it from Gemfile. ex. rubyracer gem is present in Gemfile which is used for compiling js. To avoid any issues, fallback in case compiled asset is not present should be false as compiling on runtime will not be possible due to absence of js compilers