feat(archive): use args pillar when using upstream from repo / archive
This commit is contained in:
parent
79db2125f7
commit
7a08e8db54
@ -115,7 +115,11 @@ prometheus-archive-install-{{ name }}-managed-service:
|
|||||||
workdir: {{ p.dir.var }}/{{ name }}
|
workdir: {{ p.dir.var }}/{{ name }}
|
||||||
stop: ''
|
stop: ''
|
||||||
{%- if name in ('node_exporter', 'consul_exporter') or 'config_file' not in p.pkg.component[name] %}
|
{%- if name in ('node_exporter', 'consul_exporter') or 'config_file' not in p.pkg.component[name] %}
|
||||||
start: {{ p.pkg.component[name]['path'] }}/{{ name }}
|
{%- set args = [] %}
|
||||||
|
{%- for param, value in p.pkg.component.get(name).get('service').get('args', {}).items() %}
|
||||||
|
{% do args.append("--" ~ param ~ "=" ~ value ) %}
|
||||||
|
{%- endfor %}
|
||||||
|
start: {{ p.pkg.component[name]['path'] }}/{{ name }} {{ args|join(' ') }}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
start: {{ p.pkg.component[name]['path'] }}/{{ name }} --config.file {{ p.pkg.component[name]['config_file'] }} # noqa 204
|
start: {{ p.pkg.component[name]['path'] }}/{{ name }} --config.file {{ p.pkg.component[name]['config_file'] }} # noqa 204
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
Loading…
Reference in New Issue
Block a user