Deploy files from CodeCommit to S3

丶灬走出姿态 提交于 2020-01-01 19:06:10

问题


I want to deploy certain files pushed into my CodeCommit repo into an S3 bucket. I'm attempting to do this with a Lambda trigger on the repo. However, I cannot get a list of files changed in a commit nor request a specific file from CodeCommit using the AWS CodeCommit API.

Any suggestions would be greatly appreciated!


回答1:


Yep, that capability is not in the CodeCommit API (yet... I assume/hope someone at AWS is working on it).

My suggestion would be some sort of CI job, such as a Jenkins job, using an IAM role that is configured for CodeCommit and S3 access, that regularly polls your repo(s), picks up the changes, and uses a language of your choice to handle the commit and push the changes to S3. Is this a round-about way of doing it? Yes, but I am unable to come up with an AWS-native way to do it at the moment. I would love to see someone suggest a better way.



来源:https://stackoverflow.com/questions/38270656/deploy-files-from-codecommit-to-s3

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!