How To Fail CodeDeploy When Hook Throws StdErr - Windows

1

Hi, I have CodeDeploy setup with an appspec file that calls a BeforeInstall.cmd and an AfterInstall.cmd. This is run on a Windows EC2 machine. I am finding that when there are stderr that occur within those hook scripts, the main CodeDeploy does not fail but shows as a success. I have seen people mention that you can somehow check the exit code but am unsure how to do this? Can someone shed some light on this please? Essentially, I would like the deployment to fail if there are any stderrs that occur.

thanks

gefragt vor 2 Jahren83 Aufrufe
Keine Antworten

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen