aws-codebuild

How to create a codepipeline to build jar file from java code stored at github and deploy it to lambda function?

[亡魂溺海] 提交于 2021-02-10 14:11:14
问题 I want to build a codepipeline that will get the code(java) from github build a jar file and deploy it to aws lamda(or store the jar in a specific S3 bucket). I only want to use tools provided by AWS platform only. If I am using only Codebuild I am able to build jar from the github code and store it to S3(https://docs.aws.amazon.com/codebuild/latest/userguide/getting-started.html) and I am using a deployer lamda function to deploy the code to my service lamda. Whenever there is any change in

How to create a codepipeline to build jar file from java code stored at github and deploy it to lambda function?

强颜欢笑 提交于 2021-02-10 14:06:29
问题 I want to build a codepipeline that will get the code(java) from github build a jar file and deploy it to aws lamda(or store the jar in a specific S3 bucket). I only want to use tools provided by AWS platform only. If I am using only Codebuild I am able to build jar from the github code and store it to S3(https://docs.aws.amazon.com/codebuild/latest/userguide/getting-started.html) and I am using a deployer lamda function to deploy the code to my service lamda. Whenever there is any change in

Failing to PassRole with iam:PassedToService for CodeBuild

泪湿孤枕 提交于 2021-02-07 09:31:36
问题 I'm trying to allow users to execute codebuild:StartBuild , while restricting iam:PassRole to pass the custom codebuild role only to the CodeBuild service. The canned policies never restrict iam:PassRole , and even use "Resource":"*" , effectively allowing passing of any role to any service. This strikes me as a bit sloppy, but maybe it's just me. The policy below is an excerpt – codebuild:StartBuild , codebuild:List* , etc, are all allowed. { "Version": "2012-10-17", "Statement": [ { "Effect

How to increase the maximum size of the AWS lambda deployment package (RequestEntityTooLargeException)?

不打扰是莪最后的温柔 提交于 2021-02-04 05:18:47
问题 I upload my lambda function sources from AWS codebuild. My Python script uses NLTK so it needs a lot of data. My .zip package is too big and an RequestEntityTooLargeException occurs. I want to know how to increase the size of the deployment package sent via the UpdateFunctionCode command. I use AWS CodeBuild to transform the source from a GitHub repository to AWS Lambda . Here is the associated buildspec file: version: 0.2 phases: install: commands: - echo "install step" - apt-get update -

How to access AWS CodeBuild reports in a Lambda?

我是研究僧i 提交于 2021-01-29 20:08:49
问题 At the moment I have an EventBridge sending CodeBuild build phase updates that have status "FAILED" to a Lambda. Specifically - unit tests are run and then a report is created that contains information about all the tests that were run. The event that is received by my Lambda from CodeBuild contains ARN for the reports and I would like the Lambda to read that ARN, access the report and output what's gone wrong. I can't seem to find a way to access the CodeBuild report within a Lambda - AWS

what is the CIDR range for the AWS CodeBuild service?

不羁的心 提交于 2021-01-28 20:12:19
问题 In my codebuild project I want to connect to a private 3rd party service. Which range of IPs should this service accept to allow CodeBuild to connect to it? 回答1: According to the documentation, you can find the CIDR ranges from ip-ranges.json. In case you want to get the CIDR ranges using code, refer to here. 来源: https://stackoverflow.com/questions/60921239/what-is-the-cidr-range-for-the-aws-codebuild-service

AWS ECS Blue/Green CodePipeline: Exception while trying to read the image artifact

爷,独闯天下 提交于 2021-01-28 11:50:55
问题 I wanted to create a CodePipeline which builds a container image from CodeCommit source and afterwards deploys the new image in Blue/Green fashion to my ECS service (EC2 launchtype). The source stage is CodeCommit, which already includes appspec.json as well as taskdef.json The build stage is building the new container & pushing it to ECR successfully, the file imagedefinition.json is the BuildArtifact created at this step, containing the container and the recently created image with its tag

Limited time when using local cache in AWS CodeBuild?

安稳与你 提交于 2021-01-27 07:03:38
问题 I am trying to use the Docker layer cache in AWS CodeBuild. I have seen the effect when using it to reduce the time when building or pulling Docker image, but I found that it can only use local cache in a certain time period (about less than 1 hour). I have not seen any document about this. Where did I get confused or do I have a way to set up the cache storage time? Build caching in CodeBuild 回答1: Local cache modes are best effort. They are available for a limited time after the build

Upload CodeBuild artifacts *if* they exist

主宰稳场 提交于 2021-01-24 09:39:20
问题 I have a simple CodeBuild spec that defines artifacts to be uploaded after tests run: artifacts: files: - cypress/**/*.png discard-paths: yes These artifacts are only generated if the test-action fails (a screenshot is captured of the failing test screen) and are being successfully uploaded to S3. In the case that tests succeed, no .png files will be generated and the CodeBuild action fails: [Container] 2018/09/21 20:06:34 Expanding cypress/**/*.png [Container] 2018/09/21 20:06:34 Phase

Upload CodeBuild artifacts *if* they exist

℡╲_俬逩灬. 提交于 2021-01-24 09:39:06
问题 I have a simple CodeBuild spec that defines artifacts to be uploaded after tests run: artifacts: files: - cypress/**/*.png discard-paths: yes These artifacts are only generated if the test-action fails (a screenshot is captured of the failing test screen) and are being successfully uploaded to S3. In the case that tests succeed, no .png files will be generated and the CodeBuild action fails: [Container] 2018/09/21 20:06:34 Expanding cypress/**/*.png [Container] 2018/09/21 20:06:34 Phase