copr-fe: adds PAGURE_INSTANCES
This commit is contained in:
parent
3fff578533
commit
70a00e6925
3 changed files with 31 additions and 8 deletions
|
@ -26,3 +26,8 @@ whitelist_emails:
|
|||
- dturecek@redhat.com
|
||||
- thrnciar@redhat.com
|
||||
- schlupov@redhat.com
|
||||
|
||||
copr_pagure_events:
|
||||
io.pagure.prod.pagure: "https://pagure.io/"
|
||||
org.fedoraproject.prod.pagure: "https://src.fedoraproject.org/"
|
||||
io.pagure.stg.pagure: "https://stg.pagure.io"
|
||||
|
|
|
@ -107,8 +107,17 @@ WHITELIST_EMAILS = [
|
|||
]
|
||||
{% endif %}
|
||||
|
||||
{% if not devel %}
|
||||
PAGURE_INSTANCES = ['io.pagure.prod.pagure', 'org.fedoraproject.prod.pagure']
|
||||
{% else %}
|
||||
PAGURE_INSTANCES = ['io.pagure.prod.pagure', 'org.fedoraproject.prod.pagure', 'io.pagure.stg.pagure']
|
||||
PAGURE_EVENTS = {
|
||||
{% if copr_pagure_events %}
|
||||
{% for instance, url in copr_pagure_events.items() %}
|
||||
{% for topic in [
|
||||
'git.receive',
|
||||
'pull-request.new',
|
||||
'pull-request.rebased',
|
||||
'pull-request.updated',
|
||||
'pull-request.comment.added'] %}
|
||||
'{{ instance }}.{{ topic }}' : '{{ url }}',
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
}
|
||||
|
|
|
@ -80,8 +80,17 @@ WHITELIST_EMAILS = [
|
|||
]
|
||||
{% endif %}
|
||||
|
||||
{% if not devel %}
|
||||
PAGURE_INSTANCES = ['io.pagure.prod.pagure', 'org.fedoraproject.prod.pagure']
|
||||
{% else %}
|
||||
PAGURE_INSTANCES = ['io.pagure.prod.pagure', 'org.fedoraproject.prod.pagure', 'io.pagure.stg.pagure']
|
||||
PAGURE_EVENTS = {
|
||||
{% if copr_pagure_events %}
|
||||
{% for instance, url in copr_pagure_events.items() %}
|
||||
{% for topic in [
|
||||
'git.receive',
|
||||
'pull-request.new',
|
||||
'pull-request.rebased',
|
||||
'pull-request.updated',
|
||||
'pull-request.comment.added'] %}
|
||||
'{{ instance }}.{{ topic }}' : '{{ url }}',
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue