distributing Windows client software (firefox, chrome, etc.)

86 views
Skip to first unread message

Maximilian Sarta

unread,
Oct 17, 2017, 3:15:38 PM10/17/17
to Salt-users
Hello everybody,
I am looking for a documentation for distributing Windows client software (firefox, chrome, etc.). I work with the repo-ng and it worked great.
Now I wanted work with "states" and a bit more complex configurations ... an now I get stucked by connect the xx.sls files from the repo-ng with some new states...

Does one of you, know a good tutorial or a documentation?

Thanks a lot

Shane Lee

unread,
Oct 18, 2017, 1:23:41 PM10/18/17
to Salt-users
`repo-ng` is a part of winrepo. Here's the documentation about winrepo: https://docs.saltstack.com/en/latest/topics/windows/windows-package-manager.html

You should be able to use `pkg.installed` the same way you have been using `pkg.install`.

For example, on the command line you installed firefox like this:

salt * pkg.install firefox

To do this using states, you would create a state file with the following:

# contents /srv/salt/win/firefox.sls
install_firefox:
  pkg.installed:
    - name: firefox

Then you would apply the state using the following command:

salt * state.sls win.firefox

More information on Salt's state system is here: https://docs.saltstack.com/en/latest/topics/tutorials/starting_states.html

More information on Salt's pkg state module is here: https://docs.saltstack.com/en/latest/ref/states/all/salt.states.pkg.html

Hope this helps

Shane

vchauhan

unread,
Nov 2, 2017, 12:24:31 PM11/2/17
to Salt-users
Hey Maximilian,

Can please post what configurations you made for repo-ng, As I did all the things which are given in documentation. But giving the error "unable to locate the package"

Shane Lee

unread,
Nov 3, 2017, 9:27:40 AM11/3/17
to Salt-users
There are a few possibilities here. Perhaps you did not update the got repos. Make sure to run the following in your master:

salt-run winrepo.update_git_repos

And then update the database on your minion by running

salt * pkg.refresh_db

If you've done all this already, then you may need to do some further investigation into the software definition file itself.

These are stored on the master at

/srv/salt/win/repo-ng

All files in this directory and sub directories are synced down to the minion and used to refresh the database. The .also file for the software you're trying to install will be in one of these directories. You'll want to look at the 'installer' value and make sure that the URL is accessible from the minion.

If your still having problems, please post the name of the package you're trying to install along with it's sls file.

Matthew X. Economou

unread,
Nov 25, 2017, 8:14:42 AM11/25/17
to salt-...@googlegroups.com
Maximilian Sarta writes:

> I am looking for a documentation for distributing Windows client
> software (firefox, chrome, etc.). I work with the repo-ng and it worked
> great.

> Now I wanted work with "states" and a bit more complex configurations
> ... an now I get stucked by connect the xx.sls files from the repo-ng
> with some new states...

Use a `pkg.installed` state just like on FreeBSD, Linux, or Solaris. For example:

```yaml
firefox:
pkg.installed:
[]
```

--
"The lyf so short, the craft so longe to lerne."

Reply all
Reply to author
Forward
0 new messages