0

I have an ASG and Codedeploygroup and lifecycle hook attached to that ASG.

Now the scenario here is i have an instance that is shared and three lifecycle hooks are attached to it deploying from three different codedeploy group.

Issue: My instance shuts down at night and spins up in morning, so once it spins up back then all thre lifecycle hook tries to deploy the code to instance and it runs for some day but mostly gets fails. Out of 7 days a week it fails 5 days.

'''Launching a new EC2 instance: i-000ca10c4e05b3953. Status Reason: Instance failed to complete user's Lifecycle Action: Lifecycle Action with token 3b5aac03-8478-4fad-b012-729120c9a78e was abandoned: Lifecycle Action Completed with ABANDON Result '''

I know the temporary solution to it:

Remove the lifecycle hook and let the ASG spin up the instance and then deploy manually.

But can i have a permanent solution to this, so manual interruption is completely avoided?

Anuj Kishor
  • 191
  • 1
  • 2
  • 8

1 Answers1

0

Looks like the timeout on the lifecycle hook is too slow for your processes to complete in time. You should adjust the timeout to a suitable value for your processes which may not be much more given that it's sometimes working. Although thats assuming the process is working correctly and not masking your deploy processes failing to run.

lprentice
  • 204
  • 2
  • 6