Hi there,

I was looking for a way to bootstrap pkg automatically for use with Ansible but things like this would fail:

ansible all -m raw -a 'yes | pkg info'
192.168.2.16 | FAILED | rc=1 >>
The package management tool is not yet installed on your system.
Do you want to fetch and install it now? [y/N]:

The problem wasn't Ansible though as I tried the command 'yes | pkg info' locally and it still wouldn't work.

After lots of Googling I found this: https://dan.langille.org/2013/12/06/bootstrapping-installing-pkg-on-freebsd-unattended-and-without-answering-yes

I tried the following:

ansible all -m raw -a 'env ASSUME_ALWAYS_YES=YES pkg bootstrap'

which worked flawlessly.

Now the issue I have is that I could not find a reference to 'env ASSUME_ALWAYS_YES' in either the handbook (http://www.freebsd.org/doc/handbook/pkgng-intro.html) or in the man pages:
http://www.freebsd.org/cgi/man.cgi?query=pkg&sektion=7

My questions are:
1. Is there another way of doing this?
2. If not, can a reference/note be added in one of the above mentioned pages ? I think this is a pretty important piece of information to be left out.

Many thanks,
- Lampros
_______________________________________________
freebsd-doc@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-doc
To unsubscribe, send any mail to "freebsd-doc-unsubscr...@freebsd.org"

Reply via email to