Added code to install required gems when script is run in OpsWorks.