help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DPKGPackageCheck() implementation.


From: John Sechrest
Subject: Re: DPKGPackageCheck() implementation.
Date: Mon, 15 Mar 2004 13:29:47 -0800

I see. I found the previous post. That will be helpful



Russell Adams <RLAdams@Kelsey-Seybold.com> writes:

 % I'm referring to the "debian_pkgs.cf" file I was discussing from my
 % Saturday post from home. ;]
 % 
 % I can email it to you directly if need be.
 % 
 % Suffice it to say that using that config file, I can define
 % DselectUpgrade from a time class to trigger the install.
 % 
 % The following classes trigger apt actions:
 % 
 % UpdatePackageLists    Loads a known file into dpkg --set-selections
 %                    instead of adding packages line by line/
 % UpdateApt          Updates the apt package database. (ie: security fixes)
 % CleanApt           Cleans out the apt download cache.
 % DebianUpgrade              Calls "apt-get upgrade" to upgrade existing 
packages.
 % DselectUpgrade             Calls "apt-get dselect-upgrade" to
 %                    install/remove packages based on what was fed to
 %                    UpdatePackageLists above.
 % 
 % As each of the above complete, they define a success class that can be
 % used to trigger post-install actions. See the config.
 % 
 % Russell
 % 
 % On Mon, Mar 15, 2004 at 12:53:57PM -0800, John Sechrest wrote:
 % > 
 % > What do you use to trigger the running of dselect-upgrade?
 % > 
 % > 
 % > 
 % > Russell Adams <RLAdams@Kelsey-Seybold.com> writes:
 % > 
 % >  % The '--set-selections' option is cumulative in my experience. You can
 % >  % call it multiple times with any number of packages, and the
 % >  % dselect-upgrade gets them all. That means you don't have to maintain a
 % >  % large monolithic package list.
 % >  % 
 % >  % Hence, you could just do the following to specify a package:
 % >  % 
 % >  % shellcommands:
 % >  % 
 % >  %         MyPackage::
 % >  % 
 % >  %         "/bin/sh -c \"echo 'mypackage install' | dpkg 
--set-selections\""
 % >  % 
 % >  % Afterward, run the dselect-upgrade and all the packages that had been
 % >  % set will be installed.
 % >  % 
 % >  % I use the text files to hold an initial copy of "dpkg
 % >  % --get-selections" so that I can track the overall package list. Since
 % >  % I maintain my configs outside cfengine, a simple package list is no
 % >  % big deal.
 % >  % 
 % >  % For my apps and local customizations, I use one liners like above or
 % >  % small files with multiple package specifications for dependencies and
 % >  % the like.
 % >  % 
 % >  % Russell
 % >  % 
 % >  % On Mon, Mar 15, 2004 at 09:17:53PM +0100, Morten Werner Olsen wrote:
 % >  % > On Sat, Mar 13, 2004 at 03:17:02PM -0600, Russell Adams wrote:
 % >  % > 
 % >  % > > I've been testing the enclosed configuration for my network.
 % >  % > > 
 % >  % > > I figured this was on topic, but didn't require a module.
 % >  % > > 
 % >  % > > Basically I'm maintaining packages by editing the output from "dpkg
 % >  % > > --get-selection" kept in a text file. This is imported with
 % >  % > > UpdatePackageLists, and any missing packages installed via
 % >  % > > DselectUpgrade.
 % >  % > 
 % >  % > The problem I see here is when you want to have different
 % >  % > configuration (packages installed) on your hosts. In my project, I
 % >  % > have a lot of servers with the same base configuration but the servers
 % >  % > are going to run different services from what the customer wants. In
 % >  % > the same configuration we also want to add the inhouse servers,
 % >  % > workstations and laptops. Then we could reuse the base configuration
 % >  % > and the configuration for some of the services.
 % >  % > 
 % >  % > If I should have used dpkg's --[get|set]-selections, I have had to 
have
 % >  % > one dpkg --get-selections file for each service, but now I make one
 % >  % > Cfengine-file for each service, which I find more general and clean. I
 % >  % > also like the idea of having as much configuration information as
 % >  % > possible in the Cfengine setup, and minimize the usage of external
 % >  % > files (masterfiles, info-files like the output from dpkg
 % >  % > --get-selections and scripts).
 % >  % > 
 % >  % > But I understand that in smaller configurations, usage of dpkg's
 % >  % > --[get|set]-selections is easier and fully functional. I'm also
 % >  % > interested in weaknesses you can see in my config (would be great
 % >  % > material for my project report)! :)
 % >  % > 
 % >  % > 
 % >  % > - Werner
 % >  % > 
 % >  % > 
 % >  % > _______________________________________________
 % >  % > Help-cfengine mailing list
 % >  % > Help-cfengine@gnu.org
 % >  % > http://mail.gnu.org/mailman/listinfo/help-cfengine
 % >  % 
 % >  % 
 % >  % _______________________________________________
 % >  % Help-cfengine mailing list
 % >  % Help-cfengine@gnu.org
 % >  % http://mail.gnu.org/mailman/listinfo/help-cfengine
 % > 
 % > -----
 % > John Sechrest          .         Helping people use
 % >                         .           computers and the Internet
 % >                           .            more effectively
 % >                              .                      
 % >                                  .       Internet: sechrest@peak.org
 % >                                       .   
 % >                                               . 
http://www.peak.org/~sechrest
 % 
 % 
 % _______________________________________________
 % Help-cfengine mailing list
 % Help-cfengine@gnu.org
 % http://mail.gnu.org/mailman/listinfo/help-cfengine

-----
John Sechrest          .         Helping people use
                        .           computers and the Internet
                          .            more effectively
                             .                      
                                 .       Internet: sechrest@peak.org
                                      .   
                                              . http://www.peak.org/~sechrest




reply via email to

[Prev in Thread] Current Thread [Next in Thread]