Installing Applications on Windows
Salt maintains a repo of common installers, including installing chocolatey
generate repo cache file, this will update the winrepo git details
salt-run winrepo.update_git_repos
Then update the repository cache file on your minions, exactly how it's done for the Linux package managers:
salt wintarget pkg.refresh_db
check all packages on target
salt wintarget pkg.list_pkgs
check the available versions of NPP that are available for install
salt wintarget pkg.available_version npp
wintarget:
6.4.2
Install NPP on target
salt wintarget pkg.install 'npp'
(should be done in few seconds)
to uninstall NPP,
salt '*' pkg.remove 'npp'
salt '*' pkg.purge 'npp'
to add a single file (for example we want to place Putty.exe into C:\Putty) add this to the windows state file
## Putty
c:\putty\putty.exe:
file.managed:
- source: salt://win/repo/putty/putty.exe
- makedirs: True