Skip to content
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

Job based secret #3

Closed
wants to merge 1 commit into from

Conversation

@willemvd
Copy link
Contributor

commented Nov 29, 2016

Setting the secret on the job is not working when using different jobs with different secrets (only the last one is stored). It the webhook cannot find the secret in Jenkins when not first triggered a new store of the secret in one of the jobs.

So, now the webhooks uses the Gogs secret defined on the job, so it can be different for each job instead of all the same (and Jenkins can find one without first manually load and save the configuration of one job)

…ch job instead of all the same (now Jenkins can even find one without first manually load and save the configuration of one job
@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Nov 30, 2016

Hi, will try the changes tonight and if everything is works fine i will merge this PR into master.

@willemvd

This comment has been minimized.

Copy link
Contributor Author

commented Nov 30, 2016

Thanks, that would be great! Really want a more secure, job based, secret usages when using this in production instead of a single secret for all jobs

@willemvd

This comment has been minimized.

Copy link
Contributor Author

commented Dec 6, 2016

@sanderv32 do you have time to fix this? Otherwise I need to start setting stuff up to manually supply this to Jenkins

@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Dec 6, 2016

Hi, i have to do this tonight but it can take a while before it shows up in the official repo (+/- 8 hours). So if you are in a real hurry you have to do it manually for the time being.

@willemvd

This comment has been minimized.

Copy link
Contributor Author

commented Dec 6, 2016

Ok I will wait for that (hopefully the 8 hours is my sleeping time ;))

@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Dec 6, 2016

Tested #3 and worked in the test environment. 👍

@sanderv32 sanderv32 closed this Dec 6, 2016
@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Dec 7, 2016

#3 is merged although the jenkins plugin wiki doesn't show the new version yet it's there under the archive link.

@willemvd

This comment has been minimized.

Copy link
Contributor Author

commented Dec 7, 2016

Found the plugin in the Update section in Jenkins
Only problem is that it is now suddenly returning {"result":"ERROR","message":"Job 'sas-ci' is not defined in Jenkins"} for an existing job.
Will investigate if this is a failure on my side or what goes wrong

@Silox

This comment has been minimized.

Copy link

commented on f82f42c Dec 9, 2016

Seems like this change broke something in the ?job=jobname query filter. In 1.0.7, testing the webhook from Gogs resulted in a 404: "Job X is not defined in Jenkins", downgrading to 1.0.6 fixed this error.

This comment has been minimized.

Copy link
Contributor

replied Dec 9, 2016

@Silox Created an issue of your problem.

@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Dec 9, 2016

@Silox @willemvd I have debugged the plugin against my configuration and i didn't get any errors. Can you both please provide more information in #4 ?

hongta pushed a commit to hongta/gogs-webhook-plugin that referenced this pull request Jan 2, 2017
@unknwon

This comment has been minimized.

Copy link

commented Mar 2, 2017

Hi... on develop branch of Gogs, after 0.10.1 release. Gogs starts using secret for SHA256 HMAC of payload, will that affect this functionality in this plugin?

@sanderv32

This comment has been minimized.

Copy link
Contributor

commented Mar 2, 2017

See issue #14

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.