Oh, now I see: you need to define environment variables to store your facebook_app_id and facebook_secret . You add them to your environment similar to this one (assuming a unix-like system):
Add this to the bottom of your ~/.bashrc file (or equivalent):
export FACEBOOK_APP_ID='your_id_here' export FACEBOOK_SECRET='your_secret_here'
Then open a new terminal to make sure that they are loading into the environment.
Finally, in your omniauth.rb initializer omniauth.rb enter exactly:
Rails.application.config.middleware.use OmniAuth::Builder do provider :facebook, ENV['FACEBOOK_APP_ID'], ENV['FACEBOOK_SECRET'] end
More about the topic here , for example.
You can also use the dotenv gem to process environment variables.
source share