问题
There was an error setting up your hook: Sorry, the URL host localhost is not supported because it isn't reachable over the public Internet. While adding webhook getting this error.
回答1:
You are using a local ip address. If you run ipconfig or ifconfig, you see the "local" ip address.
Github needs your public ip address. For example go to https://whatismyipaddress.com/ and it will show your public address. If you're running Jenkins on localhost:8080, then Github needs http://myPublicIP:8080 as the url. Then you have to forward the port 8080 on your router to the computer running Jenkins.
来源:https://stackoverflow.com/questions/59208288/webhook-error-issue-while-integrating-github-with-jenkins