[openSUSE/open-build-service] 0d9b2f: Re-introduce the skip of the validate_params callback
Branch: refs/heads/validate_token_trigger_workflow Home: https://github.com/openSUSE/open-build-service Commit: 0d9b2f3e815a893df2ce82f55c855fb1f809ec9a https://github.com/openSUSE/open-build-service/commit/0d9b2f3e815a893df2ce82... Author: Saray Cabrera Padrón <scabrerapadron@suse.de> Date: 2021-04-28 (Wed, 28 Apr 2021) Changed paths: M src/api/app/controllers/trigger_controller.rb Log Message: ----------- Re-introduce the skip of the validate_params callback GitLab sends data as parameters which are not strings, like the project hash. That validation would prevent us to receive webhooks from GitLab. Co-authored-by: Eduardo Navarro <enavarro@suse.com> Commit: 85e8adb0f6dbcd73326eaf78fe5157e1b2128d32 https://github.com/openSUSE/open-build-service/commit/85e8adb0f6dbcd73326eaf... Author: Saray Cabrera Padrón <scabrerapadron@suse.de> Date: 2021-04-29 (Thu, 29 Apr 2021) Changed paths: M src/api/app/models/token.rb A src/api/app/models/token/workflow.rb A src/api/app/policies/token/workflow_policy.rb M src/api/config/routes/api_routes.rb Log Message: ----------- Define the new Token::Workflow This token will handle the incoming webhooks/events from SCMs like GitHub or GitLab. Co-authored-by: Eduardo Navarro <enavarro@suse.com> Commit: d616fb48ff1d43c66517d5f22dc650c1b930987c https://github.com/openSUSE/open-build-service/commit/d616fb48ff1d43c66517d5... Author: Saray Cabrera Padrón <scabrerapadron@suse.de> Date: 2021-04-30 (Fri, 30 Apr 2021) Changed paths: M src/api/app/controllers/trigger_controller.rb A src/api/app/controllers/trigger_workflow_controller.rb M src/api/app/models/token/rebuild.rb M src/api/app/models/token/workflow.rb A src/api/app/services/trigger_controller_service/scm_extractor.rb M src/api/config/routes/api_routes.rb Log Message: ----------- Extract data from a incoming SCM's webhook This kind of webhooks trigger the new Token::Workflow. They come from SCMs like GitHub or GitLab. We extract the data from the payload of the incoming webhook/event, then check that the event and data are valid, and add it to the token as attributes. We create a new controller with the behaviour of the token workflow. Co-authored-by: Daniel Donisa <daniel.donisa@suse.com> Co-authored-by: Eduardo Navarro <enavarro@suse.com> Compare: https://github.com/openSUSE/open-build-service/compare/0d9b2f3e815a%5E...d61...
participants (1)
-
Saray Cabrera Padrón