1 Reply Latest reply on Apr 27, 2015 2:41 PM by Chad Johnson

    Using Custom Property Classes in a blpackage

    Chad Johnson

      I need help.  I'm trying to create a blpackage which will set values based upon server properties.  For this example, I want to set the nameserver entries in /etc/resolv.conf to the values in the corresponding property instance.

       

      I have created the following property class:

      Capture.JPG

      Of that class I have created two instances (ADC and CLT).  Each instance contains the appropriate values for the NIX_NAMESERVER_1, NIX_NAMESERVER_2 and NIX_NAMESERVER_3 properties.

      Capture.JPG

       

      In my blpackage I have defined this:

      Capture.JPG

      The server I'm targeting has the following property set:

      Capture.JPG

       

      I was trying to create a blpkg which would use the appropriate custom property class instance (ADC or CLT) as identified by the "NIX_LOCATION" server property.  Note: this is the same custom property class created above.  This is not working although it seems like it should.   If, in the blpackage local property, I set "Default value:" to either the ADC or CLT property class instance it works correctly. 

       

      I need this to be dynamic as when the job is executed the person executing the job will not know which setting should be set.  The blpackage needs to 'figure it out' dynamically.

       

      Can this be done?

        • 1. Re: Using Custom Property Classes in a blpackage
          Chad Johnson

          Ok, so I believe I was making this more complicated than it needs to be.

           

          I kept the same custom property class and instances above but deleted all references to them via local properties from the blpackage.

           

          Capture.JPG

          Now, in my blpackage i just use "??TARGET.NIX_LOCATION.NIX_NAMESERVER_1?? and it pulls the correct data from the property instance!

           

          I hate it when I overthink things