title: recommended way to install mongodb on elastic beanstalk
body: <p>I have already taken a look at <a href="https://stackoverflow.com/questions/24653625/how-to-install-mongodb-in-elastic-beanstalk">How to install mongodb in Elastic Beanstalk?</a> dated 2014, which no longer works. as well as <a href="https://docs.mongodb.org/ecosystem/platforms/amazon-ec2/#manually-deploy-mongodb-on-ec2" rel="noreferrer">https://docs.mongodb.org/ecosystem/platforms/amazon-ec2/#manually-deploy-mongodb-on-ec2</a></p>
  
  <p>I have set up a new elastic beanstalk environment running on node.js with 1 ec2 micro instance '64bit Amazon Linux 2016.03 v2.1.0 running Node.js'</p>
  
  <p>I have already tried using ssh to connect into my instance and install the mongodb packages using yum command:</p>
  
  <pre><code>$ sudo yum install -y mongodb-org-server mongodb-org-shell mongodb-org-tools
  </code></pre>
  
  <p>and received this call back:</p>
  
  <pre><code>Loaded plugins: priorities, update-motd, upgrade-helper
  No package mongodb-org-server available.
  No package mongodb-org-shell available.
  No package mongodb-org-tools available.
  Error: Nothing to do
  </code></pre>
  
  <p>When I first ssh 'd into my instance, I received this error warning:</p>
  
  <pre><code>This EC2 instance is managed by AWS Elastic Beanstalk. Changes made via SSH 
  WILL BE LOST if the instance is replaced by auto-scaling. For more information 
  on customizing your Elastic Beanstalk environment, see our documentation here: 
  http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customize-containers-ec2.html
  </code></pre>
  
  <p>Currently my environment is set up as a single instance environment, to save on costs. However, in the future I will upgrade to an auto-scaling environment. </p>
  
  <p>Because of this, I am asking is it recommendable to make any changes via ssh in ec2, or should I only be using EB CLI?</p>
  
  <p>I have both EC2 and EB CLI installed locally, however I have never used EB CLI before. If I should be using EB, does anyone have a recommended way to install mongodb?</p>