[gitlab] Install irker from Debian Sid to add IRC webhooks

Signed-off-by: Yohann D'ANELLO <ynerant@crans.org>
certbot_on_virtu
Yohann D'ANELLO 2021-02-22 02:40:54 +01:00
parent 85afe1fd32
commit 98eaeaa53b
Signed by: _ynerant
GPG Key ID: 3A75C55819C8CF85
6 changed files with 60 additions and 0 deletions

View File

@ -19,3 +19,6 @@ glob_gitlab:
smtp:
address: "{{ query('ldap', 'ip', 'redisdead', 'adm') | first }}"
port: 25
glob_irker:
name: GitlabBot

View File

@ -11,9 +11,12 @@
vars:
certbot: '{{ loc_certbot | default(glob_certbot | default([])) }}'
gitlab: '{{ glob_gitlab | default({}) | combine(loc_gitlab | default({}), recursive=True) }}'
irker: '{{ glob_irker | default({}) | combine(loc_irker | default({})) }}'
mirror: '{{ glob_mirror | default({}) | combine(loc_mirror | default({})) }}'
nginx: '{{ glob_nginx | default({}) | combine(loc_nginx | default({})) }}'
reverseproxy: '{{ glob_reverseproxy | default({}) | combine(loc_reverseproxy | default({})) }}'
roles:
- certbot
- gitlab
- nginx
- irker

View File

@ -0,0 +1,5 @@
---
- name: Reload irker
systemd:
name: irkerd
state: restarted

View File

@ -0,0 +1,34 @@
---
- name: Pin irker from bullseye
template:
src: "apt/{{ item }}.j2"
dest: "/etc/apt/{{ item }}"
loop:
- sources.list.d/sid.list
- preferences.d/irker-sid
when:
- ansible_distribution == "Debian"
- ansible_distribution_major_version | int <= 11
- ansible_distribution_release != "sid"
- name: Install Irker for IRC support
apt:
update_cache: true
install_recommends: false
name:
- irker
register: apt_result
retries: 3
until: apt_result is succeeded
- name: Setup Irker parameters
lineinfile:
path: /etc/default/irker
regexp: "^LAUNCH_AT_STARTUP="
line: 'IRKER_OPTIONS="-n {{ irker.name }} -d warning"'
create: true
owner: root
group: root
mode: 0644
notify: Reload irker

View File

@ -0,0 +1,12 @@
{{ ansible_header | comment }}
Package: *
Pin: release n=sid
Pin-Priority: 1
Package: irker
Pin: release n=sid
Pin-Priority: 900

View File

@ -0,0 +1,3 @@
{{ ansible_header | comment }}
deb http://{{ mirror.name }}/debian sid main