debian - how to get debain package unpacked first before debconf prompt is shown? -
I am working on a Debian packaging source to install some files on the user machine. The common argument that is being used by debconf / config script and postinst script, therefore, I put a common argument in a separate file and it is / usr / share / pkg-name /. / P /
as part of the package. Now when I install the package using DPKG, everything works fine. The first package is unpacked and the file containing the normal code base is placed on that path. After the debconf / config script the file is read and then the user gets the signal accordingly.
When I put a file in APT repo, then when I install it using apt-get, the same process is reversed. Package is not unpacked, instead a debug prompt is shown and the config script is unable to find the script with the normal code base.
I want to know why there is a difference in the establishment process? Is there a way to get the same sequence when installing via app-to-a? All three files are shell scripts.
Is there a better way to handle this common code base than to be used by various maintenance scripts?
The search is finished!
Now I understand the whole process as described in the debconf manpage. If you call it, then there are different steps or steps. They are:
- dpkg-preconfigure
- dpkg -i
- dpkg- reconfigure
All these steps start with debconf communication with the user when one uses a DPKG -i package, then the configuration script only runs with the same command line options before running the postinst script. As long as debconf communication begins, the package is already unpacked.
When someone installs a package using an APT-received, the first DPKG-preconfiguration is run, which executes the configuration script, and then DPKG-which then runs the same configured script.
In the second case of the APT-Mill, when the script script is run as part of DPKG-preconfiguration, the package has yet to be unpacked, so I had to face this problem.
If the files have been unpacked or I have to exit
if [[! -f / usr / share / pkg-name / common-codeb]]; In this way, when installing the package using apt-get, dpkg-preconfigure attempts are made to run config script, while the second attempt is awarded to DPKG-I. This works for me because I ask user about debconf questions which do not affect any other package. If you have shared the template and your choice can affect anything outside the package, remember that even though your signal is still being installed by apt-get other related / dependent packages However, DPKG will prompt the user during the pre-structuring phase. Make sure it's okay for you to solve this.
Comments
Post a Comment