help-cfengine
[Top][All Lists]
Advanced

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

Re: Platform string


From: Morgan Ives
Subject: Re: Platform string
Date: Mon, 08 Sep 2003 14:50:02 -0500

Guys,
   I use this type of constuction with variations.
          Morgan

control:
  sunos_5_6::
         klass = ( "56" )
  sunos_5_7::
         klass = ( "57" )
  sunos_5_8::
         klass = ( "58" )
 copy:
${repos}/inetd.conf.sun${klass} dest=/etc/inet/inetd.conf

 
 

"Ferguson, Steve" wrote:

I don't know how I can take those classes and insert them in a string.  I
need something I can declare in a variable.  I'm using it something like
this in update.conf:

  master_binaries = ( /var/cfengine/master/binaries/$(arch) )

  # Update important binaries
  $(master_binaries)/cfagent    dest=$(workdir)/bin/cfagent
                                mode=0755
                                backup=false
                                type=checksum
                                server=$(policyhost)

I know that the classes you mentioned are defined, but not how to get those
tokens in place of $(arch).

Steve

> -----Original Message-----
> From: Jeff Wasilko [mailto:jeffw@smoe.org]
> Sent: Monday, September 08, 2003 2:37 PM
> To: Ferguson, Steve
> Cc: Cfengine List (E-mail)
> Subject: Re: Platform string
>
>
> On Mon, Sep 08, 2003 at 01:28:05PM -0400, Ferguson, Steve wrote:
> > I'm looking to create a variable that can give me essentially this:
> >
> > uname -sr | tr ' ' '_'
> >
> > E.g.
> >
> > SunOS_5.8
> > HP-UX_B.11.00
> > Linux_2.4.20-20.9
>
> In cfengine 2.0x, I get classes like this, which look close to
> what you want:
>
>
> sunos_5_9 sunos_sun4u_5_9
>
> The dot wouldn't be valid in a class name, IIRC.
>
> -j
>

_______________________________________________
Help-cfengine mailing list
Help-cfengine@gnu.org
http://mail.gnu.org/mailman/listinfo/help-cfengine

-- 
 Morgan Ives / Senior Unix Administrator 
 Engineering Support Services / NCSG Information Technology
 Motorola Semiconductor Products Sector
 512.996.6785 (voice) 512.996.7755 (fax) 888.894.5079 (pager)

------------------------------------------------------------------------ 
  Motorola Document Classification 
  [X]  General business information 
  [ ]  Motorola internal use only 
  [ ]  Motorola confidential proprietary 
  ------------------------------------------------------------------------
 
reply via email to

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