From 9da000c6511e85e030e431b7d951d325c2c98681 Mon Sep 17 00:00:00 2001 From: mh Date: Wed, 2 Oct 2013 10:28:01 +0200 Subject: Improve the overall experience of the module. - Extending the README - Add a trocla::yaml class for a simple quickstart. - Fixes issues: #4 & #5 --- manifests/config.pp | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'manifests/config.pp') diff --git a/manifests/config.pp b/manifests/config.pp index ebae2f1..a3a6e01 100644 --- a/manifests/config.pp +++ b/manifests/config.pp @@ -1,18 +1,26 @@ #Installs configuration files for the trocla agent/CLI # #Options -# [*adapter*] Defines the adapter type to use for trocla agent. Generally YAML -# [*adapter_options*] This will contain a hash of the actual options to pass the -# trocla configuration. Generally you might pass the file option for key-file -# [*keysize*] Define the length of default passwords to create. 16 by default +# [*adapter*] Defines the adapter type to use for trocla agent. +# By default it's YAML +# [*adapter_options*] This will contain a hash of the adapter options to pass the +# trocla configuration. +# [*password_length*] Define the length of default passwords to create. 16 by default +# [*random_passwords*] Should trocla generate random passwords +# if none can be found. *true* by default. +# [*manage_dependencies*] Whether to manage the dependencies or not. Default *true* class trocla::config ( - $adapter = undef, - $keysize = 16, - $adapter_options = { 'default' => '' }, + $adapter = 'YAML', + $password_length = 16, + $random_passwords = true, + $adapter_options = {}, + $manage_dependencies = true, ) { - require trocla::master + if $manage_dependencies { + require trocla::master + } -# Deploy default config file and link it for trocla cli lookup + # Deploy default config file and link it for trocla cli lookup file{ "${settings::confdir}/troclarc.yaml": ensure => present, -- cgit v1.2.3