A simple listener that will trigger custom scripts when it receives events from GitHub.
$ git clone git@github.com:suhay/github-webhooks-listener.git
$ cd github-webhooks-listener
$ python setup.py install --user
API_TOKEN=YOUR_GITHUB_SECRET
.
├── README.md
└── sites
└── my-site.json
my-site.json
{
"path": "/home/code/my-site",
"release": {
"build": "yarn && yarn build",
"deploy": "rsync -av --delete public/ /var/www/html/my-site"
}
}
As of v0.1.0
- Only the release
event is supported.
https://{domain}/webhooks/{repo}
or
https://yoursite.com/webhooks/my-site
The repo
name must match the repository name (minus the user/org name) sent from GitHub and also the respective .json
file that contains its custom scripts.