diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-08-03 15:09:25 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-08-03 15:09:25 +0300 |
commit | aeee636c18f82107ec7a489f33c944c65ad5f34e (patch) | |
tree | 2c30286279e096c9114e9a41a3ed07a83293c059 /app/services/web_hook_service.rb | |
parent | 3d8459c18b7a20d9142359bb9334b467e774eb36 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services/web_hook_service.rb')
-rw-r--r-- | app/services/web_hook_service.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/services/web_hook_service.rb b/app/services/web_hook_service.rb index 6837bc47035..5bad2a1583c 100644 --- a/app/services/web_hook_service.rb +++ b/app/services/web_hook_service.rb @@ -57,6 +57,11 @@ class WebHookService end def execute + if Gitlab::SilentMode.enabled? + log_silent_mode_enabled + return ServiceResponse.error(message: 'Silent mode enabled') + end + return ServiceResponse.error(message: 'Hook disabled') if disabled? if recursion_blocked? @@ -98,6 +103,7 @@ class WebHookService def async_execute Gitlab::ApplicationContext.with_context(hook.application_context) do + break log_silent_mode_enabled if Gitlab::SilentMode.enabled? break log_rate_limited if rate_limit! break log_recursion_blocked if recursion_blocked? @@ -237,6 +243,10 @@ class WebHookService ) end + def log_silent_mode_enabled + log_auth_error('GitLab is in silent mode') + end + def log_auth_error(message, params = {}) Gitlab::AuthLogger.error( params.merge( |