-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update hookUrl to https #16
Comments
I at least think it's |
AaaaAAaarg!!! We've potentially lost all triggers received in the last 4 days :-( I removed ...we could redirect by hands to Thoughts? |
Thanks a lot for reporting!!! |
...actually, latest release of [email protected] was gone :( |
Change |
I have to check whether I can change/create new webhooks using the user tokens present in the DB. Is this what you mean with
? |
Yeah that's what I meant, just assumed github had a way of updating webhooks. I don't have any better ideas at the moment. |
In principle yes! You can use the API to modify whatever you wish (based on the permission scopes you asked on signup...) I'll try to confirm this during the weekend. |
Did you get any time to look into if it was possible to use the stored api key to request new webhooks with https instead? |
no, I'm sorry :-( |
No problem at all, I just wondered. If I get some time to spare I might try and check if I'm able to request new webhook with a previous api key. |
Good news! var hookDetails = {
user: "MeteorPackaging",
repo: "autopublish-test",
id: 4797246,
};
github.authenticate({
type: "token",
token: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
});
github.repos.getHook(hookDetails, function(err, res){
console.log('GET HOOK:');
console.log(err);
console.log(res);
if (!err) {
hookDetails.name = res.name;
hookDetails.config = res.config;
hookDetails.events = ['release'];
hookDetails.config.url = res.config.url.replace('http://', 'https://');
github.repos.updateHook(hookDetails, function(err, res){
console.log('UPDATE HOOK:');
console.log(err);
console.log(res);
});
}
}); I was able to succesfully update the hook even without having the user logged in! :-) I've also confimed that the same doesn't work in case the user had revoked the app authorization and that we get an error in case the hook does not exists anymore... I'd say there's everything we need to do a batch update, but we should be careful to notice which hooks we're not able to update so to ask repo maintainers to update them manually. This said, now it's not the right time to write such a migration procedure... ;-) Thanks for your support! |
This is great news! Yes ofc, as people are depending on the service we need to be careful on how and when we do the update, we don't want another blunder like the last one 👍 |
I've just switched again to This allows to get users on I've also updated the hook address accordingly so that new registrations will trigger on |
Just checked again and unfortunately I won't be able to automatically update existing hooks. Nevermind, I'll try to automatically generate an issue on source repositories to kindly ask to manually update the hook address to |
👍 Great work |
We can't toggle new web hooks right now. Pretty critical bug.
The text was updated successfully, but these errors were encountered: