diff --git a/defaults/main.yml b/defaults/main.yml index 8cadc5e..287184d 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -15,8 +15,8 @@ loki_storage_dir: /var/lib/loki loki_tags: [] -loki_listen_address: '127.0.0.1' -loki_listen_port: '3100' +loki_listen_address: 127.0.0.1 +loki_listen_port: 3100 loki_binary_local_dir: '' diff --git a/tasks/install.yml b/tasks/install.yml index 12a3039..55b5168 100644 --- a/tasks/install.yml +++ b/tasks/install.yml @@ -70,13 +70,11 @@ - name: create systemd service unit template: - src: loki.service.j2 - dest: /etc/systemd/system/loki.service + src: "{{ item }}.service.j2" + dest: "/etc/systemd/system/{{ item }}.service" owner: root group: root mode: 0644 - notify: - - restart loki + notify: "restart {{ item }}" loop: "{{ loki_bins }}" - when: - - item == 'loki' + when: item == 'loki' or item == 'promtail' diff --git a/tasks/main.yml b/tasks/main.yml index 3602128..17fe52e 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -1,8 +1,8 @@ --- -# - include: preflight.yml +- include: preflight.yml -# - include: install.yml -# become: true +- include: install.yml + become: true - include: configure.yml become: true