最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - Travis CI with Amazon Elastic Beanstalk - Stack Overflow

programmeradmin2浏览0评论

I have a web application .jsp that is currently being hosted on Amazon Elastic Beanstalk with a Java backend.

The flow process that I have in mind is this:

  • Commit to GitHub repo
  • Travis CI is triggered. Run unit tests.
  • All test cases pass. Deploy on Amazon elastic beanstalk.

Currently, I am stuck at Step 3, where I am attempting to link up Travis CI with Amazon elastic beanstalk.

I have searched for information online with regards to this but was unable to find anything that seems to be useful. The best information source that I obtained was:

I understand that Travis CI is able to deploy to Google App Engine directly, and thus I believe that there should be a solution for Amazon Elastic Beanstalk as well.

Could anyone kindly point me to resources that could potentially help me solve this issue?

Thanks!

I have a web application http://codefu-5euzxjdg6b.elasticbeanstalk.com/codeKungfu.jsp that is currently being hosted on Amazon Elastic Beanstalk with a Java backend.

The flow process that I have in mind is this:

  • Commit to GitHub repo
  • Travis CI is triggered. Run unit tests.
  • All test cases pass. Deploy on Amazon elastic beanstalk.

Currently, I am stuck at Step 3, where I am attempting to link up Travis CI with Amazon elastic beanstalk.

I have searched for information online with regards to this but was unable to find anything that seems to be useful. The best information source that I obtained was: https://superuser.com/questions/510593/elastic-beanstalk-rails-application-with-git-source-and-deploy-hooks

I understand that Travis CI is able to deploy to Google App Engine directly, and thus I believe that there should be a solution for Amazon Elastic Beanstalk as well.

Could anyone kindly point me to resources that could potentially help me solve this issue?

Thanks!

Share Improve this question edited Mar 20, 2017 at 10:18 CommunityBot 11 silver badge asked Apr 10, 2013 at 5:59 Alvin KwangAlvin Kwang 1111 silver badge3 bronze badges
Add a comment  | 

2 Answers 2

Reset to default 22

As of 9th Dec 2014, Elastic Beanstalk deployment is not covered in Travis CI deployment documentation: http://docs.travis-ci.com/user/deployment/

However, Travis CI has open sourced their deployment tool: dpl and Elastic Beanstalk deployment is an ongoing development: https://github.com/travis-ci/dpl

It's best to refer to the source itself to figure out how to do the deployment.

At present, here's a working sample of my deployment settings in .travis.yml:

deploy:
  provider: elasticbeanstalk
  access_key_id: <AWS Access Key>
  secret_access_key:
    secure: <secure secret access key>
  region: <region, eg. ap-southeast-1>
  app: <app name>
  env: <environment name>
  bucket_name: <S3 bucket name that is used by elastic beanstalk>
  on:
    repo: <repo name>
    branch: develop

Did you end up making progress on this? I think that it should be possible with Travis's encrypted variables to store a key or your AWS credentials. Then you could use those credentials with the AWS API to do the deploy itself from within your .travis.yml after_script section.

发布评论

评论列表(0)

  1. 暂无评论