diff options
author | Ralf Jung <post@ralfj.de> | 2015-02-22 22:41:07 +0100 |
---|---|---|
committer | Ralf Jung <post@ralfj.de> | 2015-02-22 22:41:07 +0100 |
commit | 5e4cc8e8aed90a3f5464cbdd1656e47bf3fc810e (patch) | |
tree | 761d966919be1c200cc497c4fbbd7ef51b8a89a3 /webhook.py | |
parent | d82914054bb75574c2675649a943025e57fa8680 (diff) |
look out for the github event type
Diffstat (limited to 'webhook.py')
-rwxr-xr-x | webhook.py | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -46,5 +46,9 @@ query = urllib.parse.parse_qs(query) repository = query.get('repository', []) repository = repository[0] if len(repository) else '' +# get GitHub metadata +githubEvent = os.getenv('HTTP_X_GITHUB_EVENT') +githubSignature = os.getenv('HTTP_X_HUB_SIGNATURE') + # execute the actual script -os.execlp("sudo", "sudo", "-n", "-u", "git", webhook_core, repository) +os.execlp("sudo", "sudo", "-n", "-u", "git", webhook_core, repository, str(githubEvent), str(githubSignature)) |