Search code examples
ubuntu-14.04aws-code-deploy

How can I get more information about a failed CodeDeploy deployment?


I've just started working with AWS CodeDeploy.

My first few deployments have failed, which is fine. With new tools comes new learning, and I expected to have to iterate a bit initially. Each of my first few deployments has failed in a useful way.

In the AWS Console I see something like this:

CodeDeploy failure with details and clickable "View Events" link

Here I can see some useful details. I can click the View Events link to see even more details, and from there I can view logs on the target EC2 instance.

In contrast, my most recent failed deployment shows this:

CodeDeploy failure without details or links

As you can see, this is missing much of the detail from the previous screenshot. The missing View Events link is particularly unfortunate. It might be significant that this deployment took longer to fail, but not long enough that one of my hook scripts might have reached its timeout.

Re-deploying resulted in the same thing.

How should I go about troubleshooting this?


Solution

  • After trying this one more time while keeping an eye on /var/log/aws/codedeploy-agent/codedeploy-agent.log I realized that there was no new log activity being generated.

    Restarting the agent with sudo /etc/init.d/codedeploy-agent restart and deploying again generated the output I expected.