2
votes

I'm trying to delete an automatically start of my CodePipeline in AWS.

My code is hosted in GitHub and the first step in my Pipeline is getting the source from there.

Every push to the branch that was configured in the Pipeline is triggering a new pipeline execution.

How can I remove this Webhook?

I try

  • I removed all the webhooks from github, but it's still trigger
3
Not really a question, as you answer it yourself. Go remove the webhook from the GitHub repo configuration.dmulter
I removed all the webhooks from github, but it still trigger! :(Eugenio Valeiras
I would look in the headers and body of the POST request then for information on where it came from.dmulter
How can I check this?Eugenio Valeiras
Looks to me like it may have fallen back to polling GitHub for changes. If you've exhausted their documentation, you might be best served by posting the question to an AWS forum instead. Good luck!dmulter

3 Answers

1
votes

I resolved the issue by setting a Disable Transition between the tasks.

enter image description here

0
votes

If your reason to remove the webhook is because you want manual control over when changes are deployed to production then I'd strongly recommend adding a manual approval rather than removing the webhook.

If you still want to remove the webhook then deleting it on GitHub should be enough. Another option is to delete it from the CodePipeline side which can be done by calling the list-webhooks API to find the webhook then delete-webhook to delete it.

If your pipeline is still starting automatically then you probably still have polling enabled rather than webhooks. To disable it you need to set the PollForSourceChanges flag to false on the source action.

0
votes

I found a possible solution here, the solution was to use the Github API and list all the webhooks with that

https://developer.github.com/v3/repos/hooks/#list-hooks

After this I fount the webhook that was triggering the pipeline and I removed it using:

https://developer.github.com/v3/repos/hooks/#delete-a-hook

But still not working?? Right!