- First create sample Elastic Beanstalk application from the AWS console.
- Then create IAM group and user with policy set to AWSElasticBeanstalkFullAccess.
- Copy the user Access Key Id and secret somewhere safe.
- Create a new project folder where you create your Node-app. Here's a premade setup if you are lazy: https://github.com/TeemuKoivisto/travis-aws-node
- Remember to add npm start script!
- Setup travis yml with
travis init
andtravis setup elastic-beanstalk
. Paste your access key and secret when prompted. You can use my project's .travis.yml as a guide. - Since travis is stupid and can't actually properly setup your project you have to add manually
bucket_name
underneathdeploy
in your.travis.yml
. - Elastic Beanstalk already generated you a S3 bucket which name you should paste eg.
bucket_name: "elasticbeanstalk-us-west-2-014750007983"
- Permissions for the bucket should already be set correctly so all you have to now is add & commit your code to GitHub.
- Check Travis to see if your project is building correctly.
- In a short while EB should replace the sample application with your own! Yey.
Last active
June 1, 2017 13:36
-
-
Save TeemuKoivisto/5a052716cc31ba67934ffdc9e6d0313e to your computer and use it in GitHub Desktop.
Guide to hosting a Node.js application on Elastic Beanstalk
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment