Github Post Commit Hook Config

Michael Telford's Avatar

Michael Telford

04 Dec, 2019 04:33 PM


I have a Ruby Github project on which I'd like updated when I push to origin master. My project docs are located at:

I've tried setting up a Webhook on Github using the URL:

But Github's ping service shows the response as 200 OK with a body of INVALIDSCHEME and I can confirm that the docs have not synced with that of the origin master branch. I've tried using http in case that was the invalid scheme but it redirects back to https. I've also tried both JSON and application/x-www-form-urlencoded payloads to no avail.

Has anybody any idea's of the correct Webhook configuration needed to achieve this?

Thanks in advance,

  1. 1 Posted by Michael Telford on 04 Dec, 2019 04:45 PM

    Michael Telford's Avatar

    I've also read the article:

    But this suggests an official Github service/app/integration, all of which are now deprecated on Github.

  2. 2 Posted by Michael Telford on 13 Dec, 2019 04:00 PM

    Michael Telford's Avatar

    So I've added a step to my CI workflow (rather than setting up a post commit hook on Github) which updates the site by curling the server:

    $ curl '' \
      -H 'User-Agent: curl' \
      -H 'Accept: */*' \
      -H 'Accept-Language: en-GB,en;q=0.5' --compressed \
      -H 'Content-Type: application/x-www-form-urlencoded' \
      -H 'X-Requested-With: XMLHttpRequest' \
      -H 'Origin:' \
      -H 'Connection: keep-alive' \
      -H 'Referer:' \
      --data 'scheme=git&'

    You can do the same by replacing the wgit repo/gem name with your own.

    I still think that the original question/issue requires a solution however since you should be able to update the docs via a Github hook. If anybody knows the correct Github hook config, please leave a comment.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac