This operator can be used to create webhook on GitHub from a kubernetes object.
helm repo add operator-github-webhook https://camptocamp.github.io/operator-github-webhook/
helm install my-release operator-github-webhook
With the following k8s object to create a webhook on this repository.
The operator is configured with environment variables:
GITHUB_TOKEN(required): GitHub token used to manage the webhooks, it needs theadmin:repo_hookscope (or theWebhooks: Read and writepermission).GITHUB_API_URL(optional): base URL of the GitHub API, defaults tohttps://api.github.com.GITHUB_WEBHOOK_SECRET(optional): default webhook secret, can be overridden in the k8s object.LOG_LEVEL(optional): defaults toINFO.REQUESTS_TIMEOUT(optional): timeout in seconds of the GitHub API requests, defaults to10.
Install the pre-commit hooks:
pip install pre-commit
pre-commit install --allow-missing-config