Hi Steven,
r10k does not accept Puppet variables or facts as it run's outside of
Puppet, the confusion is because Gary's example is using the awesome r10k
puppet module by Zack to setup the r10k configuration, hence it can use the
puppet facts or variables to create and manage the /etc/r10k.yaml
configuration file.
The created r10k configuration file should something like the example
below, which deploys environment directories with manifests and modules to
/etc/puppetlabs/puppet/environments and environmental hieradata to
/etc/puppetlabs/puppet/hieradata
--------------------
# The location to use for storing cached Git repos
:cachedir: '/var/cache/r10k'
# A list of git repositories to create
:sources:
# This will clone the git repository and instantiate an environment per
# branch in /etc/puppetlabs/puppet/environments
:local:
remote: 'git://localhost/puppet-environments-nohiera.git'
basedir: '/etc/puppetlabs/puppet/environments'
:hieradata:
remote: 'git://localhost/puppet-hieradata.git'
basedir: '/etc/puppetlabs/puppet/hieradata'
:purgedirs:
- '/etc/puppetlabs/puppet/environments'
--------------------
Regards
Jacob
On 26 March 2014 17:40, Steven James <[email protected]> wrote:
> Hi all.
>
> I'm trying to get r10k to pull down a hieradata repo, and deploy it to the
> appropriate
>
> I've added the following section to /etc/r10k.yaml
>
> hda-hieradata:
>
> remote: 'ssh://[email protected]/puppet/blah-hieradata.git'
>
> basedir: "/etc/puppet/environments/${::environment}/hieradata/"
>
> prefix: true
>
>
> I also tried - basedir: "{::confdir}/hiera" - which also didn't work.
>
>
> Is r10k able to use variables in the basedir?
>
>
> This post would suggest that it may be possible;
>
>
> http://garylarizza.com/blog/2014/03/07/puppet-workflow-part-3b/
>
>
> e.g. 'basedir'
> => "${::settings::confdir}/hiera",
>
>
> Any thoughts from anybody?
>
>
> Regs,
>
>
> Steven
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/CAB_ORUsw53%2B3MrnixWXUxoO5G2RZgqjymNNPu2zs0WB-LTNbdQ%40mail.gmail.com<https://groups.google.com/d/msgid/puppet-users/CAB_ORUsw53%2B3MrnixWXUxoO5G2RZgqjymNNPu2zs0WB-LTNbdQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/CAOQMBgxRKZkzHxsB0hpUXBWkmJq3oXOWyd-QQ8N0GR%3D6Yo24Ug%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.