fix loopabull template, add systemd template unit

Signed-off-by: Adam Miller <admiller@redhat.com>
This commit is contained in:
Adam Miller 2017-06-01 19:32:42 +00:00
parent a61d1b560e
commit 16ea698b98
3 changed files with 47 additions and 10 deletions

View file

@ -67,6 +67,7 @@
- fedmsg/base
- {
role: loopabull,
loglevel: info,
plugin: fedmsg,
routing_keys: [
"org.fedoraproject.prod.buildsys.build.state.change"
@ -95,3 +96,19 @@
copy:
src: "{{files}}/loopabull/serializer.py"
dest: "/etc/fedmsg.d/serializer.py"
- name: Install the loopabull@.service template
copy:
src: "{{files}}/loopabull/loopabull@.service"
dest: "/usr/lib/systemd/system/loopabull@.service"
- name: start and enable loopabull@
service:
name: "{{ item }}"
state: started
enabled: yes
with_items:
- loopabull@1
- loopabull@2
- loopabull@3
- loopabull@4
- loopabull@5

View file

@ -17,9 +17,3 @@
repo: "https://pagure.io/releng-automation.git"
dest: "{{playbooks_dir}}"
- name: start and enable loopabull
service:
name: loopabull
state: started
enabled: yes

View file

@ -3,11 +3,37 @@
# There are three main definitions: ansible, routing_keys, plugin. These will be
# explained in comments above each section below.
# plugin
# loglevel
#
# This is the selected plugin that will interface with your prefered origin of
# events (message bus or otherwise).
plugin: {{plugin}}
# The defaul loglevel is "info" but the following log levels are available
# - info
# - warn
# - error
# - debug
{% if loglevel is defined %}
loglevel: {{ loglevel }}
{% else %}
loglevel: info
{% endif %}
# plugin section
#
# loopabull has two types of plugins:
#
# looper: message bus python generator plugin that will interface with your
# prefered origin of events (message bus or otherwise).
#
# translator: routing key translator which allows for alternative layouts
# on-disk for routing_key mappings to playbooks the default of
# "rkname" simple means that your playbooks share the same parent
# dir and are all named after the routing_key they correspond to
# in the message bus.
#
plugins:
looper:
name: {{ plugin }}
translator:
name: rkname
# routing_keys
#