mirror of
https://pagure.io/fm-orchestrator.git
synced 2026-04-08 13:18:04 +08:00
Disable Greenwave gating by default
This commit is contained in:
@@ -124,6 +124,7 @@ class TestConfiguration(BaseConfiguration):
|
||||
RESOLVER = 'db'
|
||||
|
||||
ALLOWED_GROUPS_TO_IMPORT_MODULE = set(['mbs-import-module'])
|
||||
GREENWAVE_DECISION_CONTEXT = 'osci_compose_gate_modules'
|
||||
|
||||
|
||||
class ProdConfiguration(BaseConfiguration):
|
||||
|
||||
@@ -537,10 +537,8 @@ class Config(object):
|
||||
},
|
||||
'greenwave_decision_context': {
|
||||
'type': str,
|
||||
'default': 'osci_compose_gate_modules',
|
||||
'desc': 'The Greenwave decision context that whose messages should '
|
||||
'be handled by MBS. By default, MBS handles Greenwave '
|
||||
'messages for OSCI.',
|
||||
'default': '',
|
||||
'desc': 'The Greenwave decision context that determines a module\'s gating status.',
|
||||
},
|
||||
'allowed_disttag_marking_module_names': {
|
||||
'type': list,
|
||||
|
||||
@@ -63,6 +63,11 @@ def decision_update(config, session, msg):
|
||||
``greenwave.decision.update``.
|
||||
:type msg: :class:`GreenwaveDecisionUpdate`
|
||||
"""
|
||||
if not config.greenwave_decision_context:
|
||||
log.debug('Skip Greenwave message %s as MBS does not have GREENWAVE_DECISION_CONTEXT '
|
||||
'configured', msg.msg_id)
|
||||
return
|
||||
|
||||
if msg.decision_context != config.greenwave_decision_context:
|
||||
log.debug('Skip Greenwave message %s as MBS only handles message in '
|
||||
'decision context %s',
|
||||
|
||||
Reference in New Issue
Block a user