Skip to content

Commit

Permalink
Merge pull request #64 from systemli/fix-systemd-collector-service
Browse files Browse the repository at this point in the history
fix collector systemd service
  • Loading branch information
nevart authored Apr 9, 2024
2 parents 6e006c9 + d132c11 commit 79284b9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
9 changes: 3 additions & 6 deletions tasks/metrics.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
- name: Copy Textfile Collector Service
- name: Copy Textfile Collector Service and Timer
ansible.builtin.template:
src: "{{ item }}.j2"
dest: "/etc/systemd/system/{{ item }}"
Expand All @@ -13,11 +13,8 @@
- userli-collector.service
- userli-collector.timer

- name: Enable Textfile Collector Service
- name: Enable Textfile Collector Timer
ansible.builtin.systemd:
name: "{{ item }}"
name: userli-collector.timer
enabled: yes
state: started
loop:
- userli-collector.service
- userli-collector.timer
3 changes: 0 additions & 3 deletions templates/userli-collector.service.j2
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,3 @@ DefaultDependencies=no
Type=oneshot
ExecStart=/bin/bash -c 'php {{ userli_symfony_path }}/bin/console app:metrics | sponge {{ userli_prometheus_textfile_collector_path }}/userli.prom'
SyslogIdentifier=userli-textfile-collector

[Install]
WantedBy=multi-user.target

0 comments on commit 79284b9

Please sign in to comment.