Questions tagged [aws-code-deploy]

AWS CodeDeploy is a service that automates code deployments to Amazon EC2 instances.

AWS CodeDeploy is a service that automates code deployments to Amazon EC2 instances. AWS CodeDeploy makes it easier for you to rapidly release new features, helps you avoid downtime during deployment, and handles the complexity of updating your applications. You can use AWS CodeDeploy to automate deployments, eliminating the need for error-prone manual operations, and the service scales with your infrastructure so you can easily deploy to one EC2 instance or thousands.

1086 questions
9
votes
1 answer

How do I make AWS CodeDeploy to use AWS CodeCommit as a Git repo?

I cant't find any documentation about this! Every example is based on GitHub repos but how can I do this with AWS CodeCommit?
8
votes
5 answers

before install: CodeDeploy agent was not able to receive the lifecycle event. Check the CodeDeploy agent logs on your host and make sure the agent is

I have set up a pipeline, but i get the following error during deployment: before install CodeDeploy agent was not able to receive the lifecycle event. Check the CodeDeploy agent logs on your host and make sure the agent is running and can connect…
David
  • 2,926
  • 1
  • 27
  • 61
8
votes
2 answers

AWS CodePipeline "An AppSpec file is required, but could not be found in the revision"

I'm trying to set up a deployment pipeline using CodeCommit, ECR and ECS. My pipeline passes the source and build steps fine. I can deploy manually via CodeDeploy if I upload my appspec.yaml file to an s3 bucket. Deploys triggered by a change to my…
Ryan Quinn
  • 1,175
  • 1
  • 15
  • 28
8
votes
1 answer

Why does CodePipeline require an `imagedefinitions.json` when ECS task definitions already have this?

OK, so I have a CodePipeline which does a very vanilla CodeCommit -> Build Docker images -> CodeDeploy to ECS In the buildspec.yml file, AWS requires outputting imagedefinitions.json as an artifact that CodePipeline can use for mapping the…
lollercoaster
  • 15,969
  • 35
  • 115
  • 173
8
votes
1 answer

AWS Codedeploy BlockTraffic/AllowTraffic durations

I've been using AWS CodeDeploy to push our applications live, but it always takes ages doing the BlockTraffic and AllowTraffic steps. Currently, I have an application load balancer(ALB) with three EC2 nodes initially(behind an autoscaling group).…
8
votes
6 answers

CodeDeploy agent did not find an AppSpec file within the unpacked revision directory at revision-relative path "appspec.yml"

The CodeDeploy agent did not find an AppSpec file within the unpacked revision directory at revision-relative path "appspec.yml". The revision was unpacked to directory…
Raghuram Milkuri
  • 81
  • 1
  • 1
  • 3
8
votes
3 answers

AWS CodeDeploy Command Not Found

When trying to deploy a Node.js application I'm getting an error npm: command not found in my post_install.sh AfterInstall script. What's super strange is in my BeforeInstall script I run npm install -g pm2 and it works perfectly fine without any…
Charlie Fish
  • 18,491
  • 19
  • 86
  • 179
8
votes
4 answers

Is it possible to use AWS CodePipeline with Lightsail?

I'm working all the day and couldn't find the answer. So I'm asking you guys: is it possible to use AWS Pipeline with AWS Lightsail? My objective is to store the code inside CodeCommit and use CodeBuild, CodeDeploy, CodePipeline and S3 to create a…
8
votes
1 answer

Access AWS CodeBuild Variables in AWS CodePipeline

I am trying to use the AWS CodeBuild Id as a tag for my docker image. This docker image is built in the build phase of CodeBuild. I want to get this AWS CodeBuild Id which is my docker tag in AWS CodePipeline phase. How do I access these AWS…
8
votes
0 answers

AWS Codedeploy running out of space on EC2 instance, How to cleanup deployed Archives

Codedeploy setup which we currently have is running out of space, Now we have to manually delete the archives at location /opt/codedeploy-agent/deployment-root/. How can we clean up the archives regularly? I thought codedploy agent should take care…
Praveen Govind
  • 2,619
  • 2
  • 32
  • 45
8
votes
1 answer

AWS Error: "Access Denied" in CodeDeploy after Jenkins build

I've set up Jenkins on an EC2 instance that runs build when changes pushed to the master branch in github. Once the build on jenkins passes, it triggers a process to zip the source code and puts it in a specific S3 bucket. Then the CodeDeploy…
nael
  • 1,441
  • 19
  • 36
8
votes
4 answers

AWS Code Deploy Failing Scripts Due To Permissions

I am attempting to run a few scripts while deploying using AWS Code Deploy, but they never run due to not having permissions to run the scripts. Here is my appspec.yml file: version: 0.0 os: linux files: - source: / destination:…
gprime
  • 2,283
  • 7
  • 38
  • 50
7
votes
1 answer

What's the difference between buildspec, appspec, and rolling my own AMI?

I'm fairly confused about how the buildspec.yml and the appspec.yml files differ from one another, aside from structure. It doesn't seem like the phase commands from my buildspec have much effect on the deployment environment, and there is similar…
d8aninja
  • 3,233
  • 4
  • 36
  • 60
7
votes
6 answers

AWS CodeDeploy deployment failed at event ApplicationStop

I am trying to set up auto-deployment from GitHub to AWS, using EC2. I set Role with CodeDeployServiceRole auto policy After following the Tutorial: Use AWS CodeDeploy to Deploy an Application from GitHub, my deployment fails at the ApplicationStop…
Aviad Cohen
  • 71
  • 1
  • 1
  • 3
7
votes
1 answer

How to enable the CodeDeploy Agent on Amazon Linux 2?

Amazon Linux 2 already comes with cfn-init and other AWS integrated tools, but the CodeDeploy docs doesn't mention Amazon Linux 2 and running any service commands respond something similar to: Redirecting to /bin/systemctl start…
villasv
  • 6,304
  • 2
  • 44
  • 78
1 2
3
72 73