Add pythonpath to batch files and service

This commit is contained in:
twangboy 2017-07-26 12:21:14 -06:00
parent de2f397041
commit 4e2fb03a95
9 changed files with 25 additions and 1 deletions

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-call
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-cp
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-key
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-master
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-minion
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Stop the Salt Minion service
net stop salt-minion

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-minion
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt-run
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -8,6 +8,9 @@ Set SaltDir=%SaltDir:~0,-1%
Set Python=%SaltDir%\bin\python.exe
Set Script=%SaltDir%\bin\Scripts\salt
:: Set PYTHONPATH
Set PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages
:: Launch Script
"%Python%" "%Script%" %*

View File

@ -335,7 +335,7 @@ Section -Post
; Register the Salt-Minion Service
nsExec::Exec "nssm.exe install salt-minion $INSTDIR\bin\python.exe $INSTDIR\bin\Scripts\salt-minion -c $INSTDIR\conf -l quiet"
nsExec::Exec "nssm.exe set salt-minion AppEnvironmentExtra PYTHONHOME="
nsExec::Exec "nssm.exe set salt-minion AppEnvironmentExtra PYTHONHOME= PYTHONPATH=C:\salt\bin;C:\salt\bin\Lib\site-packages"
nsExec::Exec "nssm.exe set salt-minion Description Salt Minion from saltstack.com"
nsExec::Exec "nssm.exe set salt-minion AppNoConsole 1"