- name: ensure loki is installed package: name: loki state: present - name: ensure loki service is enabled and restarted service: name: loki state: restarted enabled: true