README.md in librarian-puppet-0.9.10 vs README.md in librarian-puppet-0.9.11

- old
+ new

@@ -1,7 +1,9 @@ # Librarian-puppet +[![Build Status](https://travis-ci.org/rodjek/librarian-puppet.png?branch=master)](https://travis-ci.org/rodjek/librarian-puppet) + ## Introduction Librarian-puppet is a bundler for your puppet infrastructure. You can use librarian-puppet to manage the puppet modules your infrastructure depends on. It is based on [Librarian](https://github.com/applicationsonline/librarian), a @@ -20,10 +22,19 @@ Every Puppet repository that uses Librarian-puppet will have a file named `Puppetfile` in the root directory of that repository. The full specification for which modules your puppet infrastructure repository depends goes in here. +### Simple Puppetfile + +This Puppetfile will download all the dependencies listed in your Modulefile from the Puppet Forge + + forge "http://forge.puppetlabs.com" + + modulefile + + ### Example Puppetfile forge "http://forge.puppetlabs.com" mod "puppetlabs/razor" @@ -36,10 +47,15 @@ :git => "git://github.com/puppetlabs/puppetlabs-stdlib.git" *See [jenkins-appliance](https://github.com/aussielunix/jenkins-appliance) for a puppet repo already setup to use librarian-puppet.* +### Recursive module dependency resolving + +When fetching a module from a `:git`-source all dependencies specified in its +`Modulefile` and `Puppetfile` will be resolved and installed. + ### Puppetfile Breakdown forge "http://forge.puppetlabs.com" This declares that we want to use the official Puppet Labs Forge as our default @@ -144,10 +160,76 @@ $ librarian-puppet update apt [--verbose] $ git diff Puppetfile.lock $ git add Puppetfile.lock $ git commit -m "bumped the version of apt up to 0.0.4." +## Configuration + +Configuration comes from three sources with the following highest-to-lowest +precedence: + +* The local config (`./.librarian/puppet/config`) +* The environment +* The global config (`~/.librarian/puppet/config`) + +You can inspect the final configuration with: + + $ librarian-puppet config + +You can find out where a particular key is set with: + + $ librarian-puppet config KEY + +You can set a key at the global level with: + + $ librarian-puppet config KEY VALUE --global + +And remove it with: + + $ librarian-puppet config KEY --global --delete + +You can set a key at the local level with: + + $ librarian-puppet config KEY VALUE --local + +And remove it with: + + $ librarian-puppet config KEY --local --delete + +You cannot set or delete environment-level config keys with the CLI. + +Configuration set at either the global or local level will affect subsequent +invocations of `librarian-puppet`. Configurations set at the environment level are +not saved and will not affect subsequent invocations of `librarian-puppet`. + +You can pass a config at the environment level by taking the original config key +and transforming it: replace hyphens (`-`) with underscores (`_`) and periods +(`.`) with doubled underscores (`__`), uppercase, and finally prefix with +`LIBRARIAN_PUPPET_`. For example, to pass a config in the environment for the key +`part-one.part-two`, set the environment variable +`LIBRARIAN_PUPPET_PART_ONE__PART_TWO`. + +Configuration affects how various commands operate. + +* The `path` config sets the cookbooks directory to install to. If a relative + path, it is relative to the directory containing the `Puppetfile`. The + equivalent environment variable is `LIBRARIAN_PUPPET_PATH`. + +* The `tmp` config sets the cache directory for librarian. If a relative + path, it is relative to the directory containing the `Puppetfile`. The + equivalent environment variable is `LIBRARIAN_PUPPET_TMP`. + +Configuration can be set by passing specific options to other commands. + +* The `path` config can be set at the local level by passing the `--path` option + to the `install` command. It can be unset at the local level by passing the + `--no-path` option to the `install` command. Note that if this is set at the + environment or global level then, even if `--no-path` is given as an option, + the environment or global config will be used. + + + ## How to Contribute * Pull requests please. * Bonus points for feature branches. @@ -160,28 +242,9 @@ * Version of ruby, librarian-puppet * What distro * Please run the `librarian-puppet` commands in verbose mode by using the `--verbose` flag, and include the verbose output in the bug report as well. -## Changelog - -### 0.9.0 - - * Initial release - -### 0.9.1 - - * Proper error message when a module that is sourced from the forge does not - exist. - * Added support for annotated tags as git references. - * `librarian-puppet init` adds `.tmp/` to gitignore instead of `tmp/`. - * Fixed syntax error in the template Puppetfile created by `librarian-puppet - init`. - * Checks for `lib/puppet` as well as `manifests/` when checking if the git - repository is a valid module. - * When a user specifies `<foo>/<bar>` as the name of a module sources from a - git repository, assume the module name is actually `<bar>`. - * Fixed gem description and summary in gemspec. ## License Please see the [LICENSE](https://github.com/rodjek/librarian-puppet/blob/master/LICENSE) file.