README.md in librarian-puppet-1.1.2 vs README.md in librarian-puppet-1.1.3

- old
+ new

@@ -26,10 +26,17 @@ It is based on [Librarian](https://github.com/applicationsonline/librarian), a framework for writing bundlers, which are tools that resolve, fetch, install, and isolate a project's dependencies. +## Versions + +Librarian-puppet >= 1.1.0 requires Ruby 1.9 and uses the Puppet Forge API v3. +Versions < 1.1.0 works on Ruby 1.8. + +See the [Changelog](Changelog.md) for more details. + ## The Puppetfile 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. @@ -45,20 +52,20 @@ ### Example Puppetfile forge "https://forge.puppetlabs.com" - mod "puppetlabs/razor" - mod "puppetlabs/ntp", "0.0.3" + mod 'puppetlabs-razor' + mod 'puppetlabs-ntp', "0.0.3" - mod "puppetlabs/apt", + mod 'puppetlabs-apt', :git => "git://github.com/puppetlabs/puppetlabs-apt.git" - mod "puppetlabs/stdlib", + mod 'puppetlabs-stdlib', :git => "git://github.com/puppetlabs/puppetlabs-stdlib.git" - mod 'puppetlabs/apache', '0.6.0', + mod 'puppetlabs-apache', '0.6.0', :github_tarball => 'puppetlabs/puppetlabs-apache' ### Recursive module dependency resolution @@ -71,33 +78,33 @@ This declares that we want to use the official Puppet Labs Forge as our default source when pulling down modules. If you run your own local forge, you may want to change this. - mod "puppetlabs/razor" + mod 'puppetlabs-razor' Pull in the latest version of the Puppet Labs Razor module from the default source. - mod "puppetlabs/ntp", "0.0.3" + mod 'puppetlabs-ntp', "0.0.3" Pull in version 0.0.3 of the Puppet Labs NTP module from the default source. - mod "puppetlabs/apt", + mod 'puppetlabs-apt', :git => "git://github.com/puppetlabs/puppetlabs-apt.git" Our puppet infrastructure repository depends on the `apt` module from the Puppet Labs GitHub repos and checks out the `master` branch. - mod "puppetlabs/apt", + mod 'puppetlabs-apt', :git => "git://github.com/puppetlabs/puppetlabs-apt.git", :ref => '0.0.3' Our puppet infrastructure repository depends on the `apt` module from the Puppet Labs GitHub repos and checks out a tag of `0.0.3`. - mod "puppetlabs/apt", + mod 'puppetlabs-apt', :git => "git://github.com/puppetlabs/puppetlabs-apt.git", :ref => 'feature/master/dans_refactor' Our puppet infrastructure repository depends on the `apt` module from the Puppet Labs GitHub repos and checks out the `dans_refactor` branch. @@ -115,11 +122,11 @@ specified subdirectory. Some people have the habit of having a single repository with many modules in it. If we need a module from such a repository, we can use the `:path =>` option here to help Librarian-puppet drill down and find the module subdirectory. - mod "puppetlabs/apt", + mod 'puppetlabs-apt', :git => "git://github.com/fake/puppet-modules.git", :path => "modules/apt" Our puppet infrastructure repository depends on the `apt` module, which we have stored as a directory under our `puppet-modules` git repos. @@ -151,9 +158,17 @@ This command looks at each `mod` declaration and fetches the module from the source specified. This command writes the complete resolution into `Puppetfile.lock` and then copies all of the fetched modules into your `modules/` directory, overwriting whatever was there before. + +Librarian-puppet support both v1 and v3 of the Puppet Forge API. +Specify a specific API version when installing modules: + + $ librarian-puppet install --use-v1-api # this is default + $ librarian-puppet install --no-use-v1-api # use the v3 API + +Please note that this does not apply for the official Puppet Forge where v3 is used by default. Get an overview of your `Puppetfile.lock` with: $ librarian-puppet show