From d987901db2269468486513a38d7cf4a99f9531c4 Mon Sep 17 00:00:00 2001 From: Dafydd Jones Date: Mon, 16 Oct 2017 17:09:19 +0100 Subject: [PATCH] fix windows minion restart command --- salt/minion.sls | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/salt/minion.sls b/salt/minion.sls index bb81f2d..cca2cbd 100644 --- a/salt/minion.sls +++ b/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 }}"'