Skip to content

Instantly share code, notes, and snippets.

@saurabhariyan
Last active October 5, 2018 17:00
Show Gist options
  • Save saurabhariyan/bb2b096be26daf1adfca821a92dc0907 to your computer and use it in GitHub Desktop.
Save saurabhariyan/bb2b096be26daf1adfca821a92dc0907 to your computer and use it in GitHub Desktop.
AWS ELB Setup

Create a key-pair and then attach it to Elastic Beanstalk environment.

  • Steps to create a key-pair

    • Login to AWS
    • Services -> EC2
    • In left under NETWORK & SECURITY select key pairs
    • Select Create new Key Pair, type key name and click on create. The key will be automatically downloaded to your system.
    • Steps to attach created key pair to Elastic Beanstalk environment
  • AWS -> Services -> Elastic Beanstalk

    • Select your environment and click on the configuration in left.
    • In Configuration overview select modify from Security.
    • Under Virtual machine permissions select key-pair that we created.
    • Click on save and then on save configuration.
    • This will take some time to reflect to your EC2 instance.

Checklist

  • Remeber to open the SSH port 22 from your ip

  • Make key-pair, attach the key pair with elastic beanstalk.

  • ssh connect :

     - chmod 400 "pem file" 
     - ssh -i "pem file" ec2-user@ec2-52-66-11-178.ap-south-1.compute.amazonaws.com
    
  • IAM account programmatic access "Access key ID,Secret access key"

  • Give nodejs user proper permissions. ebextension folder.

  • Any chnage in the environment variables from the elasticbeanstalk management console will not be reflected in your app until you redeploy it.

  • Any chnage in the envrionment varibales though will trigger an "Environment Update"

  • ^ is a illegal character in mongo password for AWS management console.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment