Using triggers with GitHub webhooks
In a CI/CD workflow, it is typical to use an event, such as a pull or push request on Git, to trigger a new pipeline run. With Tekton, you use EventListeners to listen for events and run one or more triggers. There are some out-of-the-box event processors, named Interceptors, for the following platforms:
- GitHub: This allows you to validate and filter GitHub webhooks.
- GitLab: The same as the previous point but for GitLab.
- Bitbucket: The same as the previous points for Bitbucket.
- CEL: This allows you to use Common Expression Language (CEL) to filter and modify payloads.
- Webhook: This allows you to process any webhook payload and apply any business logic to it.
In our example, we will use a GitHub interceptor to process a webhook, filter push events, and trigger the pipeline we created previously. You can also implement your custom interceptors by implementing an object named ClusterInterceptors
. Check out the links in...