Skipping or pre-setting the options in a package installation? (bsdstats)

Adam Vande More amvandemore at gmail.com
Mon Feb 2 21:32:35 UTC 2015


On Mon, Feb 2, 2015 at 1:45 PM, Matthew Pherigo <hybrid120 at gmail.com> wrote:

> Hi all,
>
> I use Ansible to administrate FreeBSD machines, and every time I install a
> pkg(8) that prompts for options (like bsdstats, which asks some simple
> yes/no questions), the install stops and waits for input that will never
> arrive. Though I'm sure that something can be improved about how Ansible
> handles this situation, I'm wondering how this can be automated or skipped
> in the first place. Perhaps there's an environment variable like
> $ALWAYS_ASSUME_YES that chooses the defaults that come with the package
> automatically?
>
> Thanks,
> --Matt
>

You can use expect/autoexpect to automate interactive cli apps.



-- 
Adam


More information about the freebsd-questions mailing list