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

git_webhook doesn't change hook after it's been created #41

Open
bschonec opened this issue Apr 10, 2018 · 2 comments
Open

git_webhook doesn't change hook after it's been created #41

bschonec opened this issue Apr 10, 2018 · 2 comments

Comments

@bschonec
Copy link

On GitLab (Github untested), the git_webhook resource doesn't modify the webhook if it already exists:

git_webhook { 'web_post_receive_webhook' :
ensure => present,
webhook_url => 'http://puppetserver.example.com:8088/payload',
token => hiera('gitlab_api_token'),
project_name => 'puppet/control-repo',
server_url => 'http://gitlab.example.com',
provider => 'gitlab',
disable_ssl_verify => false,
}

This successfully creates the webhook, but if you change:
disable_ssl_verify => true
the webhook on Gitlab doesn't get updated.

@abrader
Copy link
Owner

abrader commented Oct 30, 2018

Interesting. Will take a look to see what needs to be included in next release.

@bschonec
Copy link
Author

bschonec commented Apr 6, 2022

Updating several years later, the merge_request_events parameter doesn't update the Push event webhook if you change from true/false and re-run puppet. The issue is that the code only checks for the existence of the webhook on the Gitlab server - it does not check the validity of the parameters.

webhook_hash.keys.each do |k|
Again, Gitlab only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants