mirror of
https://pagure.io/fedora-infra/ansible.git
synced 2026-03-20 03:57:02 +08:00
Add a first test badge definition.
This commit is contained in:
31
roles/badges-backend/files/badges/test_badge.yml
Normal file
31
roles/badges-backend/files/badges/test_badge.yml
Normal file
@@ -0,0 +1,31 @@
|
||||
%YAML 1.2
|
||||
---
|
||||
|
||||
# This is some metadata about the badge
|
||||
name: Something on your mind
|
||||
description: You have commented on 2 or more bodhi updates.
|
||||
creator: ralph
|
||||
|
||||
# This is a link to the discussion about adopting this as a for-real badge.
|
||||
discussion: http://github.com/fedora-infra/badges/pull/SOME_NUMBER
|
||||
|
||||
# A link to the image for the badge
|
||||
image_url: http://upload.wikimedia.org/wikipedia/commons/5/53/PSM_V37_D209_Fisher_island_sound_rock_forming_natural_breakwater.jpg
|
||||
|
||||
# That's us!
|
||||
issuer_id: fedora-project
|
||||
|
||||
# We'll perform our more costly check (defined below) only when
|
||||
# we receive messages that match this 'trigger'
|
||||
trigger:
|
||||
topic: org.fedoraproject.stg.bodhi.update.comment
|
||||
|
||||
# Once the check has been triggered, this defines what we actually check.
|
||||
criteria:
|
||||
datanommer:
|
||||
filter:
|
||||
topics:
|
||||
- "{topic}" # The topic of the message that triggered us.
|
||||
operation: count
|
||||
condition:
|
||||
greater than or equal to: 2
|
||||
@@ -12,3 +12,14 @@
|
||||
|
||||
notify:
|
||||
- restart fedmsg-hub
|
||||
|
||||
- name: make badge definition directory
|
||||
file: path=/usr/share/badges/rules state=directory
|
||||
|
||||
- name: copy over all our badge definitions
|
||||
copy: src=$item dest=/usr/share/badges/rules/$item
|
||||
with_items:
|
||||
- badges/test_badge.yml
|
||||
|
||||
notify:
|
||||
- restart fedmsg-hub
|
||||
|
||||
Reference in New Issue
Block a user