Separate exam-mode stuff in own role

This commit is contained in:
Raphael Dannecker 2025-03-18 14:37:13 +01:00
parent 43157dd810
commit 3d01394820
13 changed files with 493 additions and 472 deletions

View file

@ -36,26 +36,3 @@
{% if 'teacherlaptop' not in group_names %}
[[ "${UID}" -gt 10000 ]] && ! findmnt /srv/samba/schools/default-school > /dev/null && exit 0
{% endif %}
- name: Provide rmexam script
ansible.builtin.copy:
src: rmexam
dest: /usr/local/sbin/
mode: 0755
when: "'teacherlaptop' not in group_names"
- name: Provide rmexam services and timers for some scripts
ansible.builtin.copy:
src: "{{ item }}"
dest: "/etc/systemd/system/{{ item }}"
mode: 0644
loop:
- rmexam.service
- rmexam.timer
when: "'teacherlaptop' not in group_names"
- name: Enable rmexam.timer
ansible.builtin.systemd:
name: rmexam.timer
enabled: true
when: "'teacherlaptop' not in group_names"