Commit 2a591c06 authored by Julien Cigar's avatar Julien Cigar 🤘
Browse files

use sv path

parent fb45f8b8
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
{% set service = runit.service_dir | path_join(name) %} {% set service = runit.service_dir | path_join(name) %}
{{ name }}_stop_service: {{ name }}_stop_service:
cmd.run: cmd.run:
- name: sv down {{ service }} - name: {{ runit.sv }} down {{ service }}
- onlyif: - onlyif:
- test -d {{ service }} - test -d {{ service }}
{%- endmacro %} {%- endmacro %}
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
- name: {{ service | path_join('run') }} - name: {{ service | path_join('run') }}
- mode: 754 - mode: 754
cmd.run: cmd.run:
- name: sv up {{ service }} - name: {{ runit.sv }} up {{ service }}
- onlyif: - onlyif:
- test -d {{ service }} - test -d {{ service }}
- test -p {{ service | path_join('supervise', 'ok') }} - test -p {{ service | path_join('supervise', 'ok') }}
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
{% set service = runit.service_dir | path_join(name) %} {% set service = runit.service_dir | path_join(name) %}
{{ name }}_restart_service: {{ name }}_restart_service:
cmd.run: cmd.run:
- name: sv restart {{ service }} - name: {{ runit.sv }} restart {{ service }}
- onlyif: - onlyif:
- test -d {{ service }} - test -d {{ service }}
{%- endmacro %} {%- endmacro %}
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
{% set service = runit.service_dir | path_join(name) %} {% set service = runit.service_dir | path_join(name) %}
{{ name }}_signal_service: {{ name }}_signal_service:
cmd.run: cmd.run:
- name: sv {{ signal }} {{ service }} - name: {{ runit.sv }} {{ signal }} {{ service }}
- onlyif: - onlyif:
- test -d {{ service }} - test -d {{ service }}
{%- endmacro %} {%- endmacro %}
......
...@@ -4,3 +4,4 @@ FreeBSD: ...@@ -4,3 +4,4 @@ FreeBSD:
pkg: runit pkg: runit
service_dir: /var/service service_dir: /var/service
service_name: runsvdir service_name: runsvdir
sv: /usr/local/bin/sv
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment