"Scott Muir" <wsmuir@islandnet.com> wrote in message [🔎] NCBBKLMCJOGCLFHOFECNGENAFLAA.wsmuir@islandnet.com">news:[🔎] NCBBKLMCJOGCLFHOFECNGENAFLAA.wsmuir@islandnet.com...
(noob) I would like to know if and how it is possible to do a non-interactive install of an .deb package. The pages I have read talk only of a 'yes to all questions' option which is obviously useless if the package you are installing has questions other than yes/no and so on.The docs also speak of being able to set *arbitrary* options in the command line. This seemed to be more related to the apt-get program rather than thepackages. Two examples I want to do are Apache2 and PostgreSQL which require some additional prompting. The purpose here is to create a set of steps whichcan quickly install a Debian system from scratch, limit down-time and removesome of the human element. Is there a way of doing this? I'm at about a 3 bananas out of 5 on the howler monkey scale.
How about debconf pre-seeding? Most programs use debconf to ask the questions. However if debconf already has answers to the questions then it does not bother to ask them. In fact the config script is apparently sometimes run in both the pre-inst and the postinst so ignoring questions which have answers already is almost critcal.
The following is one way to pre-seed debconf. With this method it is very important that you not pre-seed for any packages that will not be installed, because otherwise those values will rot in the database forever.
Anyway lets say the package name is 'foobar'
From a system where it is already configured you should run:
debconf-get-selections|grep ^foobar > foobar.preseedThen to load that into the database to avoid the questions, simply get the file onto the system and run:
debconf-get-selections foobar.preseedNote thatyou can concatonate a bunch of these file together if you want. This will then let you use only one line to
pre-seed a whole bunch of packages.There are also other ways to pre-seed, but I don't know about them.