I was super excited to learn about AWS and beanstalk. I created my rails 4 project and used beanstalk to push it. When I went to the url I was greeted by my old friend the nginx error screen. “502 bad gateway”. WTF! I ssh’d in to the box and in the logs I find “You must set config.secret_key_base in your app’s config”. I added config.secret_key_base = ‘dfsdsfsd’ to my application.rb and Bam! Error solved.