浏览代码

Merge pull request #339 from dafyddj/win-restart

Fix Windows minion restart command
tags/v0.57.0
Niels Abspoel 7 年前
父节点
当前提交
31e2d95203
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. +2
    -2
      salt/minion.sls

+ 2
- 2
salt/minion.sls 查看文件

@@ -22,11 +22,11 @@ salt-minion:
cmd.run:
{%- if grains['saltversioninfo'][0] >= 2016 and grains['saltversioninfo'][1] >= 3 %}
{%- if grains['kernel'] == 'Windows' %}
- name: '{{ salt_settings.config_path }}\salt-call.bat --local service.restart {{ salt_settings.minion_service }}'
- name: 'salt-call.bat --local service.restart {{ salt_settings.minion_service }}'
{%- else %}
- name: 'salt-call --local service.restart {{ salt_settings.minion_service }} --out-file /dev/null'
- bg: True
{%- endif %}
- bg: True
{%- else %}
{%- if grains['kernel'] == 'Windows' %}
- name: 'start powershell "Restart-Service -Name {{ salt_settings.minion_service }}"'

正在加载...
取消
保存