Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


A version of extlookup with a pluggable backend. The same puppet manifests can be configured to query different backends like a backward compatible CSV file, YAML files or in-module data.


You need a YAML file called extlookup.yaml in the same directory as your puppet.conf it looks like the examples below



Compatible with old extlookup, all the feature of the old extlookup and supports config using the old global variables and if those don't exist the new config file

To configure just set :datadir to a directory full of files ending in .csv

   :parser: CSV
   - environment_%{environment}
   - common
      :datadir: /etc/puppet/extdata

This configures the function to look in a per environment CSV file and then in a common one. Files are stored in /etc/puppet/extdata

This is equivelant to the old config:

$extlookup_datadir = "/etc/puppet/extdata"
$extlookup_precedence = ["environment_%{environment}", "common"]


A YAML parser that supports the same precedence and overrides. For simple String data it will do variable parsing like the old CSV extlookup but if you put a hash or arrays of hashes in your data it wont touch those.

:parser: YAML
- environment_%{environment}
- common
   :datadir: /etc/puppet/extdata

This configuration matches the above CSV configuration, all you need to do is create yaml files instead of CSV files.

Both (YAML and CSV) support variables also in the datadir option, so that for example you are able to point puppet to different datadirs depending on the current environment:

    :datadir: /etc/puppet/environments/%{environment}/extdata


A parser that reads values from Puppet manifests inspired by Nigel Kerstens get() function. Without configured precedence the behavior of this backend will be identical to the get() function

In addition to the simple features of the get() function it also includes full precedence in line with the extlookup features.

For details of the precedence behavior for this backend see the comments top of the backend.

You can also configure explicit behavior like proposed by Nigel:

:parser: Puppet
- %{calling_class}
- %{calling_module}
   :datasource: data


This is a work in progress, use at your own risk


R.I.Pienaar / / / @ripienaar