GithubHelp home page GithubHelp logo

librarian-puppet's Introduction

Librarian-puppet

NOTE This project has moved to https://github.com/voxpupuli/librarian-puppet

Build Status

Introduction

Librarian-puppet is a bundler for your puppet infrastructure. You can use librarian-puppet to manage the puppet modules your infrastructure depends on, whether the modules come from the Puppet Forge, Git repositories or just a path.

  • Librarian-puppet can reuse the dependencies listed in your Modulefile or metadata.json
  • Forge modules can be installed from Puppetlabs Forge or an internal Forge such as Pulp
  • Git modules can be installed from a branch, tag or specific commit, optionally using a path inside the repository
  • Modules can be installed from GitHub using tarballs, without needing Git installed
  • Modules can be installed from a filesystem path
  • Module dependencies are resolved transitively without needing to list all the modules explicitly

Librarian-puppet manages your modules/ directory for you based on your Puppetfile. Your Puppetfile becomes the authoritative source for what modules you require and at what version, tag or branch.

Once using Librarian-puppet you should not modify the contents of your modules directory. The individual modules' repos should be updated, tagged with a new release and the version bumped in your Puppetfile.

It is based on Librarian, a framework for writing bundlers, which are tools that resolve, fetch, install, and isolate a project's dependencies.

Versions

Librarian-puppet >= 2.0 (as well as 1.1, 1.2 and 1.3) requires Ruby 1.9 and uses the Puppet Forge API v3. Versions < 2.0 work on Ruby 1.8.

See the Changelog for more details.

The Puppetfile

Every Puppet repository that uses Librarian-puppet may have a file named Puppetfile, metadata.json or Modulefile in the root directory of that repository. The full specification for which modules your puppet infrastructure repository depends goes in here.

Simple usage

If no Puppetfile is present, librarian-puppet will download all the dependencies listed in your metadata.json or Modulefile from the Puppet Forge, as if the Puppetfile contained

forge "https://forgeapi.puppetlabs.com"

metadata

Example Puppetfile

forge "https://forgeapi.puppetlabs.com"

mod 'puppetlabs-razor'
mod 'puppetlabs-ntp', "0.0.3"

mod 'puppetlabs-apt',
  :git => "git://github.com/puppetlabs/puppetlabs-apt.git"

mod 'puppetlabs-stdlib',
  :git => "git://github.com/puppetlabs/puppetlabs-stdlib.git"

mod 'puppetlabs-apache', '0.6.0',
  :github_tarball => 'puppetlabs/puppetlabs-apache'

mod 'acme-mymodule', :path => './some_folder'

exclusion 'acme-bad_module'

Recursive module dependency resolution

When fetching a module all dependencies specified in its Modulefile, metadata.json and Puppetfile will be resolved and installed.

Puppetfile Breakdown

forge "https://forgeapi.puppetlabs.com"

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.

metadata

Download all the dependencies listed in your metadata.json or Modulefile from the Puppet Forge.

mod 'puppetlabs-razor'

Pull in the latest version of the Puppet Labs Razor module from the default source.

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',
  :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',
  :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',
  :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.

When using a Git source, we do not have to use a :ref =>. If we do not, then librarian-puppet will assume we meant the master branch.

If we use a :ref =>, we can use anything that Git will recognize as a ref. This includes any branch name, tag name, SHA, or SHA unique prefix. If we use a branch, we can later ask Librarian-puppet to update the module by fetching the most recent version of the module from that same branch.

The Git source also supports a :path => option. If we use the path option, Librarian-puppet will navigate down into the Git repository and only use the 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',
  :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.

mod 'puppetlabs-apache', '0.6.0',
  :github_tarball => 'puppetlabs/puppetlabs-apache'

Our puppet infrastructure repository depends on the puppetlabs-apache module, to be downloaded from GitHub tarball.

mod 'acme-mymodule', :path => './some_folder'

Our puppet infrastructure repository depends on the acme-mymodule module, which is already in the filesystem.

exclusion 'acme-bad_module'

Exclude the module acme-bad_module from resolution and installation.

How to Use

Install librarian-puppet:

$ gem install librarian-puppet

Prepare your puppet infrastructure repository:

$ cd ~/path/to/puppet-inf-repos
$ (git) rm -rf modules
$ librarian-puppet init

Librarian-puppet takes over your modules/ directory, and will always reinstall (if missing) the modules listed the Puppetfile.lock into your modules/ directory, therefore you do not need your modules/ directory to be tracked in Git.

Librarian-puppet uses a .tmp/ directory for tempfiles and caches. You should not track this directory in Git.

Running librarian-puppet init will create a skeleton Puppetfile for you as well as adding tmp/ and modules/ to your .gitignore.

$ librarian-puppet install [--clean] [--verbose]

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; ignored for official Puppet Forge
$ librarian-puppet install --no-use-v1-api # use the v3 API; default for official Puppet Forge

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

Inspect the details of specific resolved dependencies with:

$ librarian-puppet show NAME1 [NAME2, ...]

Find out which dependencies are outdated and may be updated:

$ librarian-puppet outdated [--verbose]

Update the version of a dependency:

$ 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 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.

Rsync Option

The default convergence strategy between the cache and the module directory is to execute an rm -r on the module directory and just cp -r from the cache. This causes the module to be removed from the module path every time librarian puppet updates, regardless of whether the content has changed. This can cause some problems in environments with lots of change. The problem arises when the module directory gets removed while Puppet is trying to read files inside it. The puppet master process will lose its CWD and the catalog will fail to compile. To avoid this, you can use rsync to implement a more conservative convergence strategy. This will use rsync with the -avz and --delete flags instead of a rm -r and cp -r. To use this feature, just set the rsync configuration setting to true.

$ librarian-puppet config rsync true --global

Alternatively, using an environment variable:

LIBRARIAN_PUPPET_RSYNC='true'

Note that the directories will still be purged if you run librarian-puppet with the --clean or --destructive flags.

How to Contribute

  • Pull requests please.
  • Bonus points for feature branches.

Reporting Issues

Bug reports to the github issue tracker please. Please include:

  • Relevant Puppetfile and Puppetfile.lock files
  • Version of ruby, librarian-puppet, and 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.

License

Please see the LICENSE file.

librarian-puppet's People

Contributors

arioch avatar aussielunix avatar benburkert avatar carlossg avatar craigtracey avatar danmindru avatar danzilio avatar ecbypi avatar fgrehm avatar gabrielbull avatar grosser avatar jabley avatar jedi4ever avatar jhaals avatar jmslagle avatar johnduhart avatar jozefizso avatar jsjohns avatar justenwalker avatar mattbostock avatar msturm avatar njam avatar petems avatar phinze avatar pschulz avatar pyromaniac avatar rodjek avatar scotje avatar wfarr avatar willdurand avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

librarian-puppet's Issues

librarian-puppet outdated is silent when using git as a source

When you have modules listed in your Puppetfile with a source of gitthat are always tracking master librarian-puppet outdated is silent even though there are updates committed to the module's repository.

It would be nice if librarian-puppet outdated was able to do a diff on the remote and report if there are changes that could be pulled in.

Cheers
Mick

Request: multiple remotes

It would be awesome if librarian-puppet would be able to support multiple git remotes.
More specifically for my use case it shouldn't remove existing ones.

Absolutely *useless* error messages if a module has a version number that makes librarian-puppet a bit sad

Version 0.9.3 (the last halfway-sensible version) says:

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/version.rb:182:in `initialize': Malformed version number string 0.5.0-rc1 (ArgumentError)

No hint about where this version number comes from. What am I meant to do with that?

Version 0.9.7 amazes and delights with its ability to be even more useless

/Library/Ruby/Gems/1.8/gems/puppet-3.0.1/lib/puppet/module_tool/metadata.rb:120:in `version=': Invalid version format:  (Semantic Versions are acceptable: http://semver.org) (ArgumentError)

It doesn't even tell me what string it took exception to!

I believe the module in question is http://forge.puppetlabs.com/puppetlabs/apache/0.5.0-rc1

Thing is, my Puppetfile already stipulates that I don't care at all about this version:

mod 'puppetlabs/apache',    "0.4.0"

So librarian-puppet is chucking a hissy fit over a version number that it refuses to tell me about unless I install an old version, even though it knows I don't care about that version.

I don't know what to do here.

Fails to fetch module from Puppet forge

When trying to fetch haraldsk/nfs:

$ librarian-puppet update
Unable to find module 'puppetlabs-stdlib' on http://forge.puppetlabs.com

puppetlabs/stdlib is a dependency of this module.

Tested on librarian-puppet 0.9.7, ruby 1.9.3p374 on Arch Linux.

Following Modulefile causes "Expected DEPENDENCIES topic!" error

A module which uses the following file causes librarian-puppet to bomb out with the following stack trace:
Modulefile:

name    'infrastructure-sssd'
version '0.0.1'
source '...'
author 'infrastructure'
license '...'
summary 'Installs & configure the SSSD authentication stack.'
description '...'
project_page '...'

## Add dependencies, if any:
# dependency 'username/name', '>= 1.2.0'

Error (last lines):

[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/87ef4d15f8b5ed59d08fa1757f4dd854
[Librarian]     --- No output
[Librarian]     Checking sssd/0.0.1 <[email protected]:infrastructure/puppet-module-sssd.git#master>
[Librarian]       Resolved sssd (>= 0) <[email protected]:infrastructure/puppet-module-sssd.git#master> at sssd/0.0.1 <[email protected]:infrastructure/puppet-module-sssd.git#master>
[Librarian]   Resolved sssd (>= 0) <[email protected]:infrastructure/puppet-module-sssd.git#master>
[Librarian] Bouncing Puppetfile.lock
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/lib/librarian/puppet/lockfile/parser.rb:41:in `parse': Expected DEPENDENCIES topic! (StandardError)
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/vendor/librarian/lib/librarian/lockfile.rb:21:in `load'
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/vendor/librarian/lib/librarian/action/resolve.rb:31:in `run'
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/vendor/librarian/lib/librarian/cli.rb:161:in `resolve!'
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/lib/librarian/puppet/cli.rb:59:in `install'
    from /usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
    from /usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
    from /usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
    from /usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
    from /usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
    from /usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.3/bin/librarian-puppet:9
    from /usr/bin/librarian-puppet:19:in `load'
    from /usr/bin/librarian-puppet:19

Puppetfile:

mod 'sssd',
  :git => '[email protected]:infrastructure/puppet-module-sssd.git'

Can't switch tags on ripienaar's concat module

Switching to a tag fails

ozymandias:production$ cat Puppetfile
mod 'concat',
  :git => 'git://github.com/ripienaar/puppet-concat.git',
  :ref => '20100507'
ozymandias:production$ rm -rf modules/ Puppetfile.lock .tmp/
ozymandias:production$ librarian-puppet install --verbose
[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: i686-darwin11
[Librarian] Rubygems Version: 1.8.13
[Librarian] Librarian Version: 0.0.23
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /Users/tom/tmp/modules/env/production
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/local/bin/git
[Librarian] Git Version: git version 1.7.9.2
[Librarian] Git Environment Variables:
[Librarian]   GIT_PS1_SHOWDIRTYSTATE=true
[Librarian]   GIT_PS1_SHOWUNTRACKEDFILES=true
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/ripienaar/puppet-concat.git", {:ref=>"20100507"}]
[Librarian] Scheduling concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#20100507>
[Librarian] Resolving concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#20100507>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian] Running `/usr/local/bin/git clone git://github.com/ripienaar/puppet-concat.git . --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Running `/usr/local/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git remote` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --> origin
[Librarian] Running `/usr/local/bin/git branch -r` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian] Running `/usr/local/bin/git rev-parse 20100507 --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --> a23258eccbc6136ec79b6c9306442dd2255f2ee6
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Running `/usr/local/bin/git checkout a23258eccbc6136ec79b6c9306442dd2255f2ee6 --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a45b26430587215f1c5b04667b4770f6
[Librarian]     --> d09acb4a426da691e2fccbed7bb26b1679fa141e
failed to checkout a23258eccbc6136ec79b6c9306442dd2255f2ee6
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/source/git.rb:109:in `cache!'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:24:in `fetch_version'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:117:in `fetch_version!'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:109:in `fetched_version'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:63:in `version'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:59:in `to_s'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:67:in `recursive_resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:113:in `debug'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/helpers/debug.rb:28:in `debug'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/ui.rb:32:in `debug'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/helpers/debug.rb:28:in `debug'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:113:in `debug'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:67:in `recursive_resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:64:in `each'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:64:in `recursive_resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:107:in `scope'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:63:in `recursive_resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:107:in `scope'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:46:in `recursive_resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:24:in `resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver.rb:19:in `resolve'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/resolve.rb:25:in `run'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:139:in `resolve!'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:75:in `install'
/opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `send'
/opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `run'
/opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/invocation.rb:120:in `invoke_task'
/opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor.rb:275:in `dispatch'
/opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/base.rb:408:in `start'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:33:in `bin!'
/opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/bin/librarian-puppet:9
/opt/local/bin/librarian-puppet:19:in `load'
/opt/local/bin/librarian-puppet:19

Using master branch works

ozymandias:production$ rm -rf modules/ Puppetfile.lock .tmp/
ozymandias:production$ cat Puppetfile
mod 'concat',
  :git => 'git://github.com/ripienaar/puppet-concat.git'
ozymandias:production$ librarian-puppet install --verbose
[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: i686-darwin11
[Librarian] Rubygems Version: 1.8.13
[Librarian] Librarian Version: 0.0.23
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /Users/tom/tmp/modules/env/production
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/local/bin/git
[Librarian] Git Version: git version 1.7.9.2
[Librarian] Git Environment Variables:
[Librarian]   GIT_PS1_SHOWDIRTYSTATE=true
[Librarian]   GIT_PS1_SHOWUNTRACKEDFILES=true
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/ripienaar/puppet-concat.git", {}]
[Librarian] Scheduling concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian] Resolving concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian] Running `/usr/local/bin/git clone git://github.com/ripienaar/puppet-concat.git . --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Running `/usr/local/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git remote` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> origin
[Librarian] Running `/usr/local/bin/git branch -r` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian] Running `/usr/local/bin/git rev-parse origin/master --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian]     Checking concat/0.0.1 <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian]       Resolved concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#master> at concat/0.0.1 <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian]   Resolved concat (>= 0) <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian] Bouncing Puppetfile.lock
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/ripienaar/puppet-concat.git", {}]
[Librarian] Installing concat/0.0.1 <git://github.com/ripienaar/puppet-concat.git#master>
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e
[Librarian]     --> 99f3eb83f77ae68664eb2b346df4e4db6f21f1b3
[Librarian] Copying .tmp/librarian/cache/source/git/877342027263f67a5b4bf66c2dbf9a6e to modules/concat

receiver.rb:52 error on puppet-librarian install

When running /var/lib/gems/1.8/bin/librarian-puppet --verbose install I get this error:

 [Librarian] Ruby Version: 1.8.7
 [Librarian] Ruby Platform: x86_64-linux
 [Librarian] Rubygems Version: 1.3.7
 [Librarian] Librarian Version: 0.0.24
 [Librarian] Librarian Adapter: puppet
 [Librarian] Project: /tmp/idg
 [Librarian] Specfile: Puppetfile
 [Librarian] Lockfile: Puppetfile.lock
 [Librarian] Git: /usr/bin/git
 [Librarian] Git Version: git version 1.7.2.5
 [Librarian] Git Environment Variables:
 [Librarian]   (empty)
 [Librarian] Pre-Cached Sources:
 /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl/receiver.rb:52:in `instance_binding': compile error (SyntaxError)
 /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl/receiver.rb:52: syntax error, unexpected $end
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl/receiver.rb:43:in `instance_binding'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl/receiver.rb:33:in `run'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl.rb:81:in `run'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl.rb:71:in `tap'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl.rb:71:in `run'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/dsl.rb:17:in `run'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/environment.rb:115:in `dsl'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/specfile.rb:14:in `read'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/resolve.rb:12:in `run'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:161:in `resolve!'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/cli.rb:63:in `install'
         from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
         from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
         from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
         from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
         from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
         from /var/lib/gems/1.8/gems/librarian-puppet-0.9.6/bin/librarian-puppet:9
         from /var/lib/gems/1.8/bin/librarian-puppet:19:in `load'
         from /var/lib/gems/1.8/bin/librarian-puppet:19

Puppetfile:

forge "http://forge.puppetlabs.com"

# mod 'puppetlabs/stdlib'

# mod 'ntp',
#   :git => 'git://github.com/puppetlabs/puppetlabs-ntp.git'

mod 'base',
   :git => '[email protected]:base',
#   :ref => 'feature/master/dans_refactor'

versions are not parsed correctly

Perhaps related to #82: Versions, in general, are not parsed correctly either:

name 'puppetlabs-apache'
version '0.5.0-rc1'

Throws librarian-puppet off, with the following error:

/lib/ruby/1.9.1/rubygems/version.rb:187:in `initialize': Malformed version number string 0.5.0-rc1 (ArgumentError)
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:12:in `new'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:12:in `initialize'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:117:in `new'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:117:in `_normalize_version'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:101:in `fetched_version'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:55:in `version'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:85:in `satisfies?'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/dependency.rb:65:in `satisfied_by?'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `block (5 levels) in recursive_resolve'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `each'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `all?'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `block (4 levels) in recursive_resolve'
    from /lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'

0.9.4 breaks with "Cannot bounce Puppetfile.lock!"

After installing 0.9.4, it keeps failing with the following stack trace. Downgrading to 0.9.3 fixes the problem:

[Librarian] Bouncing Puppetfile.lock
[Librarian] lockfile_text: 
FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-apache.git
  ref: master
  sha: 6f4be236f60ccf3f8d9d7f4e99eafa4ab56caa87
  specs:
    apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-passenger.git
  ref: master
  sha: f734c861bcb2bd01d201423baf0e3e8dd1ef65ab
  specs:
    passenger (0.0.4)
      puppetlabs/apache (>= 0.0.3)
      puppetlabs/ruby (>= 0.0.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-stdlib.git
  ref: master
  sha: 6961179007dce76d7fb9bd1fc361273acb4129a7
  specs:
    stdlib (3.0.1)

GIT
  remote: [email protected]:ashapira/puppet-module-opsview.git
  ref: master
  sha: 8916bf1053d790f1becc2721351108890f109a7f
  specs:
    opsview (0.3.0)

GIT
  remote: [email protected]:infrastructure/puppet-module-autofs.git
  ref: master
  sha: 259bb66394d3f386ce2ee7093818a765084bd3c2
  specs:
    autofs (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-nfs.git
  ref: master
  sha: a04268be275e687e5499e055964fd4dd98aeba43
  specs:
    nfs (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-ntpd.git
  ref: master
  sha: b24f216b04b74cbfa68f706c7bdd206696a314bc
  specs:
    ntpd (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-resolv.git
  ref: master
  sha: 65c53afb306026cba53196948f79a0058fa6a589
  specs:
    resolv (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-resolver.git
  ref: master
  sha: 6ec5f2f97f2926ed6fb6c126f1765e4a0c579ef7
  specs:
    resolver (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-serial.git
  ref: master
  sha: 76108b1ccc3e127dafc72788865646848df39dcb
  specs:
    serial (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-ssh.git
  ref: master
  sha: 5e33f31bf06acf59bf185f03eb0896ed59bfed39
  specs:
    ssh (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-sssd.git
  ref: master
  sha: 654538aa741276837d19bcf599652976de49cc93
  specs:
    sssd (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-sudo.git
  ref: master
  sha: dc067c455ac92b407de44415ec8ae591de663be0
  specs:
    sudo (0.0.1)

DEPENDENCIES
  apache (>= 0)
  autofs (>= 0)
  nfs (>= 0)
  ntpd (>= 0)
  opsview (>= 0)
  passenger (>= 0)
  resolv (>= 0)
  resolver (>= 0)
  serial (>= 0)
  ssh (>= 0)
  sssd (>= 0)
  stdlib (>= 0)
  sudo (>= 0)

[Librarian] bounced_lockfile_text: 
FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-apache.git
  ref: master
  sha: 6f4be236f60ccf3f8d9d7f4e99eafa4ab56caa87
  specs:
    apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-passenger.git
  ref: master
  sha: f734c861bcb2bd01d201423baf0e3e8dd1ef65ab
  specs:
    passenger (0.0.4)
      puppetlabs/apache (>= 0.0.3)
      puppetlabs/ruby (>= 0.0.1)

GIT
  remote: git://github.com/puppetlabs/puppetlabs-stdlib.git
  ref: master
  sha: 6961179007dce76d7fb9bd1fc361273acb4129a7
  specs:
    stdlib (3.0.1)

GIT
  remote: [email protected]:ashapira/puppet-module-opsview.git
  ref: master
  sha: 8916bf1053d790f1becc2721351108890f109a7f
  specs:
    opsview (0.3.0)

GIT
  remote: [email protected]:infrastructure/puppet-module-autofs.git
  ref: master
  sha: 259bb66394d3f386ce2ee7093818a765084bd3c2
  specs:
    autofs (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-nfs.git
  ref: master
  sha: a04268be275e687e5499e055964fd4dd98aeba43
  specs:
    nfs (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-ntpd.git
  ref: master
  sha: b24f216b04b74cbfa68f706c7bdd206696a314bc
  specs:
    ntpd (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-resolv.git
  ref: master
  sha: 65c53afb306026cba53196948f79a0058fa6a589
  specs:
    resolv (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-resolver.git
  ref: master
  sha: 6ec5f2f97f2926ed6fb6c126f1765e4a0c579ef7
  specs:
    resolver (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-serial.git
  ref: master
  sha: 76108b1ccc3e127dafc72788865646848df39dcb
  specs:
    serial (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-ssh.git
  ref: master
  sha: 5e33f31bf06acf59bf185f03eb0896ed59bfed39
  specs:
    ssh (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-sssd.git
  ref: master
  sha: 654538aa741276837d19bcf599652976de49cc93
  specs:
    sssd (0.0.1)

GIT
  remote: [email protected]:infrastructure/puppet-module-sudo.git
  ref: master
  sha: dc067c455ac92b407de44415ec8ae591de663be0
  specs:
    sudo (0.0.1)

DEPENDENCIES
  apache (>= 0)
  autofs (>= 0)
  nfs (>= 0)
  ntpd (>= 0)
  opsview (>= 0)
  passenger (>= 0)
  resolv (>= 0)
  resolver (>= 0)
  serial (>= 0)
  ssh (>= 0)
  sssd (>= 0)
  stdlib (>= 0)
  sudo (>= 0)

Cannot bounce Puppetfile.lock!
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/resolve.rb:35:in `run'
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/cli.rb:161:in `resolve!'
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.4/lib/librarian/puppet/cli.rb:63:in `install'
/usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
/usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
/usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
/usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
/usr/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
/usr/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.4/bin/librarian-puppet:9
/usr/bin/librarian-puppet:19:in `load'
/usr/bin/librarian-puppet:19

The diff between the lockfile_text and the bounced_lockfile_text is:

--- /tmp/old    2012-09-07 11:32:35.259971612 +1000
+++ /tmp/new    2012-09-07 11:32:50.731971574 +1000
@@ -8,36 +8,6 @@
     puppetlabs/ruby (0.0.2)
     puppetlabs/stdlib (3.0.1)

-FORGE
-  remote: http://forge.puppetlabs.com
-  specs:
-    puppetlabs/apache (0.4.0)
-      puppetlabs/firewall (>= 0.0.4)
-      puppetlabs/stdlib (>= 2.2.1)
-    puppetlabs/firewall (0.0.4)
-    puppetlabs/ruby (0.0.2)
-    puppetlabs/stdlib (3.0.1)
-
-FORGE
-  remote: http://forge.puppetlabs.com
-  specs:
-    puppetlabs/apache (0.4.0)
-      puppetlabs/firewall (>= 0.0.4)
-      puppetlabs/stdlib (>= 2.2.1)
-    puppetlabs/firewall (0.0.4)
-    puppetlabs/ruby (0.0.2)
-    puppetlabs/stdlib (3.0.1)
-
-FORGE
-  remote: http://forge.puppetlabs.com
-  specs:
-    puppetlabs/apache (0.4.0)
-      puppetlabs/firewall (>= 0.0.4)
-      puppetlabs/stdlib (>= 2.2.1)
-    puppetlabs/firewall (0.0.4)
-    puppetlabs/ruby (0.0.2)
-    puppetlabs/stdlib (3.0.1)
-
 GIT
   remote: git://github.com/puppetlabs/puppetlabs-apache.git
   ref: master

`Cannot bounce Puppetfile.lock` if dependent module is provided by git.

If a module installed from a forge is dependant on a module, and a replacement module is provided by git, then Cannot bounce Puppetfile.lock error given.

Puppetfile used:

forge "http://forge.puppetlabs.com"

mod "puppetlabs/stdlib"
mod "puppetlabs/passenger"
mod "puppetlabs/apt"

mod "apache",
    :git => "git://github.com/nesi/puppetlabs-apache.git"

Output from librarian-puppet install --verbose (piped to file):

[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: x86_64-linux
[Librarian] Rubygems Version: 1.8.15
[Librarian] Librarian Version: 0.0.24
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /etc/puppet
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/bin/git
[Librarian] Git Version: git version 1.7.9.5
[Librarian] Git Environment Variables:
[Librarian]   (empty)
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:forge, "http://forge.puppetlabs.com", {}]
[Librarian]   [:git, "git://github.com/nesi/puppetlabs-apache.git", {}]
[Librarian] Scheduling puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian] Scheduling puppetlabs/passenger (>= 0) <http://forge.puppetlabs.com>
[Librarian] Scheduling puppetlabs/apt (>= 0) <http://forge.puppetlabs.com>
[Librarian] Scheduling apache (>= 0) <git://github.com/nesi/puppetlabs-apache.git#master>
[Librarian] Resolving puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian]     Checking puppetlabs/stdlib/3.0.1 <http://forge.puppetlabs.com>
[Librarian]       Resolving puppetlabs/passenger (>= 0) <http://forge.puppetlabs.com>
[Librarian]         No known prior constraints
[Librarian]         Checking manifests
[Librarian]           Checking puppetlabs/passenger/0.0.4 <http://forge.puppetlabs.com>
[Librarian]             Scheduling puppetlabs/apache (>= 0.0.3) <http://forge.puppetlabs.com>
[Librarian]             Scheduling puppetlabs/ruby (>= 0.0.1) <http://forge.puppetlabs.com>
[Librarian]             Resolving puppetlabs/apt (>= 0) <http://forge.puppetlabs.com>
[Librarian]               No known prior constraints
[Librarian]               Checking manifests
[Librarian]                 Checking puppetlabs/apt/0.0.4 <http://forge.puppetlabs.com>
[Librarian]                   Scheduling puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                   Resolving apache (>= 0) <git://github.com/nesi/puppetlabs-apache.git#master>
[Librarian]                     No known prior constraints
[Librarian]                     Checking manifests
[Librarian] Running `/usr/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --> 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
[Librarian] Running `/usr/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git remote` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --> origin
[Librarian] Running `/usr/bin/git branch -r` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian]     -->   origin/mod_shib
[Librarian] Running `/usr/bin/git rev-parse origin/master^{commit} --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --> 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --> 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a76c4e8c8a61aeddfa2068e8f498ba08
[Librarian]     --> 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
[Librarian]                       Checking apache/0.4.0 <git://github.com/nesi/puppetlabs-apache.git#master>
[Librarian]                         Scheduling puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]                         Scheduling puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                         Resolving puppetlabs/apache (>= 0.0.3) <http://forge.puppetlabs.com>
[Librarian]                           No known prior constraints
[Librarian]                           Checking manifests
[Librarian]                             Checking puppetlabs/apache/0.4.0 <http://forge.puppetlabs.com>
[Librarian]                               Scheduling puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]                               Scheduling puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                               Resolving puppetlabs/ruby (>= 0.0.1) <http://forge.puppetlabs.com>
[Librarian]                                 No known prior constraints
[Librarian]                                 Checking manifests
[Librarian]                                   Checking puppetlabs/ruby/0.0.2 <http://forge.puppetlabs.com>
[Librarian]                                     Resolving puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                                       Accords with all prior constraints
[Librarian]                                     Resolving puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]                                       No known prior constraints
[Librarian]                                       Checking manifests
[Librarian]                                         Checking puppetlabs/firewall/0.0.4 <http://forge.puppetlabs.com>
[Librarian]                                           Resolving puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                                             Accords with all prior constraints
[Librarian]                                           Resolving puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]                                             Accords with all prior constraints
[Librarian]                                           Resolving puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]                                             Accords with all prior constraints
[Librarian]                                           Resolved puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com> at puppetlabs/firewall/0.0.4 <http://forge.puppetlabs.com>
[Librarian]                                       Resolved puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]                                     Resolved puppetlabs/ruby (>= 0.0.1) <http://forge.puppetlabs.com> at puppetlabs/ruby/0.0.2 <http://forge.puppetlabs.com>
[Librarian]                                 Resolved puppetlabs/ruby (>= 0.0.1) <http://forge.puppetlabs.com>
[Librarian]                               Resolved puppetlabs/apache (>= 0.0.3) <http://forge.puppetlabs.com> at puppetlabs/apache/0.4.0 <http://forge.puppetlabs.com>
[Librarian]                           Resolved puppetlabs/apache (>= 0.0.3) <http://forge.puppetlabs.com>
[Librarian]                         Resolved apache (>= 0) <git://github.com/nesi/puppetlabs-apache.git#master> at apache/0.4.0 <git://github.com/nesi/puppetlabs-apache.git#master>
[Librarian]                     Resolved apache (>= 0) <git://github.com/nesi/puppetlabs-apache.git#master>
[Librarian]                   Resolved puppetlabs/apt (>= 0) <http://forge.puppetlabs.com> at puppetlabs/apt/0.0.4 <http://forge.puppetlabs.com>
[Librarian]               Resolved puppetlabs/apt (>= 0) <http://forge.puppetlabs.com>
[Librarian]             Resolved puppetlabs/passenger (>= 0) <http://forge.puppetlabs.com> at puppetlabs/passenger/0.0.4 <http://forge.puppetlabs.com>
[Librarian]         Resolved puppetlabs/passenger (>= 0) <http://forge.puppetlabs.com>
[Librarian]       Resolved puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com> at puppetlabs/stdlib/3.0.1 <http://forge.puppetlabs.com>
[Librarian]   Resolved puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian] Bouncing Puppetfile.lock
[Librarian] lockfile_text: 
FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/apt (0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/passenger (0.0.4)
      puppetlabs/apache (>= 0.0.3)
      puppetlabs/ruby (>= 0.0.1)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/apt (0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/passenger (0.0.4)
      puppetlabs/apache (>= 0.0.3)
      puppetlabs/ruby (>= 0.0.1)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

GIT
  remote: git://github.com/nesi/puppetlabs-apache.git
  ref: master
  sha: 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
  specs:
    apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)

DEPENDENCIES
  apache (>= 0)
  puppetlabs/apt (>= 0)
  puppetlabs/passenger (>= 0)
  puppetlabs/stdlib (>= 0)

[Librarian] bounced_lockfile_text: 
FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/apt (0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/passenger (0.0.4)
      puppetlabs/apache (>= 0.0.3)
      puppetlabs/ruby (>= 0.0.1)
    puppetlabs/ruby (0.0.2)
    puppetlabs/stdlib (3.0.1)

GIT
  remote: git://github.com/nesi/puppetlabs-apache.git
  ref: master
  sha: 58ba4638ea6cbeddd3419e96cf54c9fc2b060bd0
  specs:
    apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)

DEPENDENCIES
  apache (>= 0)
  puppetlabs/apt (>= 0)
  puppetlabs/passenger (>= 0)
  puppetlabs/stdlib (>= 0)

๏ฟฝ[31mCannot bounce Puppetfile.lock!๏ฟฝ[0m
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/resolve.rb:35:in `run'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:161:in `resolve!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/cli.rb:63:in `install'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/bin/librarian-puppet:9
/usr/local/bin/librarian-puppet:19:in `load'
/usr/local/bin/librarian-puppet:19

pathname.rb:212:in `dup': can't dup NilClass (TypeError)

When installing the Puppetlabs create_resources module (https://github.com/puppetlabs/puppetlabs-create_resources)
the error below appears:

$ librarian-puppet clean
$ librarian-puppet install --verbose
[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: i686-darwin11
[Librarian] Rubygems Version: 1.8.13
[Librarian] Librarian Version: 0.0.23
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /tmp/libr/puppet-module-library
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/local/bin/git
[Librarian] Git Version: git version 1.7.9.2
[Librarian] Git Environment Variables:
[Librarian]   GIT_PS1_SHOWDIRTYSTATE=true
[Librarian]   GIT_PS1_SHOWUNTRACKEDFILES=true
[Librarian] Pre-Cached Sources:
[Librarian]   [:git, "git://github.com/puppetlabs/puppetlabs-create_resources.git", {}]
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/puppetlabs/puppetlabs-create_resources.git", {}]
[Librarian] The specfile is unchanged: nothing to do.
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/puppetlabs/puppetlabs-create_resources.git", {}]
[Librarian] Installing create_resources/0.0.1 <git://github.com/puppetlabs/puppetlabs-create_resources.git#master>
[Librarian] Running `/usr/local/bin/git clone git://github.com/puppetlabs/puppetlabs-create_resources.git . --quiet` in .tmp/librarian/cache/source/git/f092abca8898417ede8b287313206b49
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/f092abca8898417ede8b287313206b49
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/f092abca8898417ede8b287313206b49
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/f092abca8898417ede8b287313206b49
[Librarian]     --> 28584b0ed187fda119b3c44d468cafe7d3e1e980
/opt/local/lib/ruby/1.8/pathname.rb:212:in `dup': can't dup NilClass (TypeError)
    from /opt/local/lib/ruby/1.8/pathname.rb:212:in `initialize'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/environment.rb:103:in `new'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/environment.rb:103:in `project_relative_path_to'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/helpers/debug.rb:16:in `relative_path_to'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:36:in `install_perform_step_copy!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/helpers/debug.rb:28:in `debug'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/ui.rb:32:in `debug'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/helpers/debug.rb:28:in `debug'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:36:in `install_perform_step_copy!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:20:in `install!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:97:in `install!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:49:in `install_manifests'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:48:in `each'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:48:in `install_manifests'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:39:in `perform_installation'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:12:in `run'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:135:in `install!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:76:in `install'
    from /opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `send'
    from /opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `run'
    from /opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/invocation.rb:120:in `invoke_task'
    from /opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor.rb:275:in `dispatch'
    from /opt/local/lib/ruby/gems/1.8/gems/thor-0.15.2/lib/thor/base.rb:408:in `start'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:33:in `bin!'
    from /opt/local/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.0/bin/librarian-puppet:9
    from /opt/local/bin/librarian-puppet:19:in `load'
    from /opt/local/bin/librarian-puppet:19

is there anyway to share subdirectory using librarian-puppet

I am trying to share subdirectory within a module. for example, my repo layout is

puppet.git : modules/oldModule/manifests/sensu

i want to copy the data from "modules/oldModule/manifests/sensu" to "modules/newModule/manifests/sensu"

Was hoping something like following will work.

mod "modules/newModule/manifests/sensu",
  :git => "[email protected]:TestOrg/puppet.git",
  :path => "modules/oldModule/manifests/sensu" 

gem install of librarian-puppet-maestrodev still has issues with invalid versions

Writing this up as a separate issue, rather than keep bumping other issues.

Installing using gem seems to miss the latest commit that resolves the invalid version issue:

root@puppet:~# gem install librarian-puppet-maestrodev
Fetching: librarian-puppet-maestrodev-0.9.7.2.gem (100%)
Successfully installed librarian-puppet-maestrodev-0.9.7.2
1 gem installed
Installing ri documentation for librarian-puppet-maestrodev-0.9.7.2...
Installing RDoc documentation for librarian-puppet-maestrodev-0.9.7.2...
root@puppet:~# cd /etc/puppet
root@puppet: /etc/puppet# librarian-puppet install
root@puppet: /etc/puppet# date
Thu Jan 24 13:35:48 PST 2013
root@puppet: /etc/puppet# gem list -Vd librarian-puppet

*** LOCAL GEMS ***

librarian-puppet-maestrodev (0.9.7.2)
    Author: Tim Sharpe
    Homepage: https://github.com/rodjek/librarian-puppet
    Installed at: /var/lib/gems/1.9.1

    Bundler for your Puppet modules

Has the gem provided on RubyGems been updated after 6b42807 ?

Or is Ubuntu 12.10 getting the gems from a different source?

gem install still brings in a bunch of other gems

I'm trying to do a basic RPM package for libarian. When I do the packaging I notice that there are still a lot of dependencies getting brought in, even if I tell the gem installer to ignore them. This isn't just the puppet gem.

Reproduce with this:

gem install --remote --install-dir /tmp/librarian --ignore-dependencies librarian-puppet
ls -1 /tmp/librarian/gems/librarian-puppet-0.9.8/vendor/gems/ruby/1.9.1/gems
aruba-0.5.1
childprocess-0.3.8
diff-lcs-1.1.3
ffi-1.3.1
hiera-1.1.2
json_pure-1.7.7
rake-10.0.3
thor-0.17.0
builder-3.1.4
cucumber-1.2.1
facter-1.6.17
gherkin-2.11.6
json-1.7.7
puppet-3.1.0
rspec-expectations-2.12.1

I spot checked the same command sequence with some of the gems that this package pulls in, and none of them do this.

"can't dup NilClass" error when running update

I am getting a "can't dup NilClass" error when running librarian-puppet update. Here is the Puppet.lockfile file:

GIT
  remote: [email protected]:base.git
  ref: 7db6b91e19b337ba194b36ffbf834599ecdf57f4
  sha: 7db6b91e19b337ba194b36ffbf834599ecdf57f4
  specs:
    base (0.0.1)

DEPENDENCIES
  base (>= 0)

The Puppet file:

mod 'base',
  :git => '[email protected]:base.git',
  :ref => '7db6b91e19b337ba194b36ffbf834599ecdf57f4'

Finally, here is the complete verbose output:

[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: x86_64-linux
[Librarian] Rubygems Version: 1.8.24
[Librarian] Librarian Version: 0.0.24
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /srv/scratch/idg
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/bin/git
[Librarian] Git Version: git version 1.7.10.4
[Librarian] Git Environment Variables:
[Librarian]   (empty)
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "[email protected]:base.git", {:ref=>"7db6b91e19b337ba194b36ffbf834599ecdf57f4"}]
[Librarian] Scheduling base (>= 0) <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian] Resolving base (>= 0) <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian] Running `/usr/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee\
9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa\
4cbe5ee9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5\
ee9d4be9
[Librarian]     --> 7db6b91e19b337ba194b36ffbf834599ecdf57f4
[Librarian] Running `/usr/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee\
9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa\
4cbe5ee9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git remote` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee9d4be9
[Librarian]     --> origin
[Librarian] Running `/usr/bin/git branch -r` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee9d4be9
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian]     -->   origin/stable201202
[Librarian]     -->   origin/stable201207
[Librarian] Running `/usr/bin/git rev-parse 7db6b91e19b337ba194b36ffbf834599ecdf57f4^{commit} --quiet` in .tmp/librar\
ian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee9d4be9
[Librarian]     --> 7db6b91e19b337ba194b36ffbf834599ecdf57f4
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5\
ee9d4be9
[Librarian]     --> 7db6b91e19b337ba194b36ffbf834599ecdf57f4
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5\
ee9d4be9
[Librarian]     --> 7db6b91e19b337ba194b36ffbf834599ecdf57f4
[Librarian]     Checking base/0.0.1 <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian]       Resolved base (>= 0) <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4> at b\
ase/0.0.1 <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian]   Resolved base (>= 0) <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian] Bouncing Puppetfile.lock
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "[email protected]:base.git", {:ref=>"7db6b91e19b337ba194b36ffbf834599ecdf57f4"}]
[Librarian] Installing base/0.0.1 <[email protected]:base.git#7db6b91e19b337ba194b36ffbf834599ecdf57f4>
[Librarian] Running `/usr/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5ee\
9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa\
4cbe5ee9d4be9
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/b8a5dc46fb3ffd9d8aa4cbe5\
ee9d4be9
[Librarian]     --> 7db6b91e19b337ba194b36ffbf834599ecdf57f4
/usr/lib/ruby/1.8/pathname.rb:212:in `dup': can't dup NilClass (TypeError)
    from /usr/lib/ruby/1.8/pathname.rb:212:in `initialize'
    from /usr/lib/ruby/vendor_ruby/librarian/environment.rb:103:in `new'
    from /usr/lib/ruby/vendor_ruby/librarian/environment.rb:103:in `project_relative_path_to'
    from /usr/lib/ruby/vendor_ruby/librarian/logger.rb:36:in `relative_path_to'
    from /usr/lib/ruby/vendor_ruby/librarian/source/local.rb:56:in `relative_path_to'
    from /usr/lib/ruby/vendor_ruby/librarian/puppet/source/local.rb:42:in `install_perform_step_copy!'
    from /usr/lib/ruby/vendor_ruby/librarian/logger.rb:31:in `debug'
    from /usr/lib/ruby/vendor_ruby/librarian/ui.rb:32:in `debug'
    from /usr/lib/ruby/vendor_ruby/librarian/logger.rb:31:in `debug'
    from /usr/lib/ruby/vendor_ruby/librarian/source/local.rb:52:in `debug'
    from /usr/lib/ruby/vendor_ruby/librarian/puppet/source/local.rb:42:in `install_perform_step_copy!'
    from /usr/lib/ruby/vendor_ruby/librarian/puppet/source/local.rb:26:in `install!'
    from /usr/lib/ruby/vendor_ruby/librarian/manifest.rb:89:in `install!'
    from /usr/lib/ruby/vendor_ruby/librarian/action/install.rb:49:in `install_manifests'
    from /usr/lib/ruby/vendor_ruby/librarian/action/install.rb:48:in `each'
    from /usr/lib/ruby/vendor_ruby/librarian/action/install.rb:48:in `install_manifests'
    from /usr/lib/ruby/vendor_ruby/librarian/action/install.rb:39:in `perform_installation'
    from /usr/lib/ruby/vendor_ruby/librarian/action/install.rb:12:in `run'
    from /usr/lib/ruby/vendor_ruby/librarian/cli.rb:157:in `install!'
    from /usr/lib/ruby/vendor_ruby/librarian/cli.rb:107:in `update'
    from /usr/lib/ruby/vendor_ruby/thor/task.rb:27:in `send'
    from /usr/lib/ruby/vendor_ruby/thor/task.rb:27:in `run'
    from /usr/lib/ruby/vendor_ruby/thor/invocation.rb:120:in `invoke_task'
    from /usr/lib/ruby/vendor_ruby/thor.rb:275:in `dispatch'
    from /usr/lib/ruby/vendor_ruby/thor/base.rb:425:in `start'
    from /usr/lib/ruby/vendor_ruby/librarian/cli.rb:29:in `bin!'
    from /usr/bin/librarian-puppet:9

Error running librarian on windows

C:/Ruby187/lib/ruby/1.8/pathname.rb:770:in read': No such file or directory - C:\Users\zykes\Documents\GitHub\puppetlabs-openstack/Puppetfile (Errno::ENOENT) from C:/Ruby187/lib/ruby/1.8/pathname.rb:770:inread'
from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/specfile.rb:14:in read' from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/resolve.rb:12:inrun'
from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/cli.rb:161:in resolve!' from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/lib/librarian/puppet/cli.rb:63:ininstall'
from C:/Ruby187/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in send' from C:/Ruby187/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:inrun'
from C:/Ruby187/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in invoke_task' from C:/Ruby187/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:indispatch'
from C:/Ruby187/lib/ruby/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in start' from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/cli.rb:29:inbin!'
from C:/Ruby187/lib/ruby/gems/1.8/gems/librarian-puppet-0.9.7/bin/librarian-puppet:9
from C:/Ruby187/bin/librarian-puppet:23:in `load'
from C:/Ruby187/bin/librarian-puppet:23

Ruby 18.x latest 1.8 series from rubyinstaller.org and these ggms:
*** LOCAL GEMS ***

archive-tar-minitar (0.5.2)
childprocess (0.3.6)
erubis (2.7.0)
facter (1.6.13)
ffi (1.1.5 x86-mingw32)
hiera (1.0.0)
i18n (0.6.1)
json (1.7.5, 1.5.4)
librarian-puppet (0.9.7)
log4r (1.1.10)
net-scp (1.0.4)
net-ssh (2.2.2)
puppet (2.7.19)
rake (0.9.2.2)
sys-admin (1.5.6 x86-mingw32)
thor (0.16.0)
vagrant (1.0.5)
win32-api (1.4.8 x86-mingw32)
win32-dir (0.3.7)
win32-process (0.6.5)
win32-security (0.1.4)
win32-service (0.7.2 x86-mingw32)
win32-taskscheduler (0.2.2)
windows-api (0.4.2)
windows-pr (1.2.2)

"Error: Read-only file system" when installing puppetlabs/apache from Puppet Forge

I am trying to use Librarian-puppet 0.9.7 to manage modules on an Ubuntu 12.04 VM created using Vagrant. I am running Librarian-puppet on the VM, not the host. If I try to install the puppetlabs/apache module from Puppet Forge, the installation fails with the error below.

If I try installing a different module, such as puppetlabs/mysql, then the installation succeeds. I am unsure if this is a bug in Librarian-puppet or a problem with the module uploaded to Puppet Forge, but you have to start somewhere so I'm raising the issue here first.

Puppetfile:

forge "http://forge.puppetlabs.com"
mod "puppetlabs/apache"

Puppetfile.lock:

FORGE
  remote: http://forge.puppetlabs.com
  specs:
    puppetlabs/apache (0.4.0)
      puppetlabs/firewall (>= 0.0.4)
      puppetlabs/stdlib (>= 2.2.1)
    puppetlabs/firewall (0.0.4)
    puppetlabs/stdlib (3.1.1)

DEPENDENCIES
  puppetlabs/apache (>= 0)

Verbose log:

[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: i686-linux
[Librarian] Rubygems Version: 1.8.15
[Librarian] Librarian Version: 0.0.24
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /vagrant/puppet
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/bin/git
[Librarian] Git Version: git version 1.7.9.5
[Librarian] Git Environment Variables:
[Librarian]   (empty)
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:forge, "http://forge.puppetlabs.com", {}]
[Librarian] Scheduling puppetlabs/apache (>= 0) <http://forge.puppetlabs.com>
[Librarian] Resolving puppetlabs/apache (>= 0) <http://forge.puppetlabs.com>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian]     Checking puppetlabs/apache/0.4.0 <http://forge.puppetlabs.com>
[Librarian]       Scheduling puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]       Scheduling puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]       Resolving puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]         No known prior constraints
[Librarian]         Checking manifests
[Librarian]           Checking puppetlabs/firewall/0.0.4 <http://forge.puppetlabs.com>
[Librarian]             Resolving puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]               No known prior constraints
[Librarian]               Checking manifests
[Librarian]                 Checking puppetlabs/stdlib/3.1.1 <http://forge.puppetlabs.com>
[Librarian]                   Resolved puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com> at puppetlabs/stdlib/3.1.1 <http://forge.puppetlabs.com>
[Librarian]               Resolved puppetlabs/stdlib (>= 2.2.1) <http://forge.puppetlabs.com>
[Librarian]             Resolved puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com> at puppetlabs/firewall/0.0.4 <http://forge.puppetlabs.com>
[Librarian]         Resolved puppetlabs/firewall (>= 0.0.4) <http://forge.puppetlabs.com>
[Librarian]       Resolved puppetlabs/apache (>= 0) <http://forge.puppetlabs.com> at puppetlabs/apache/0.4.0 <http://forge.puppetlabs.com>
[Librarian]   Resolved puppetlabs/apache (>= 0) <http://forge.puppetlabs.com>
[Librarian] Bouncing Puppetfile.lock
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:forge, "http://forge.puppetlabs.com", {}]
Error: Read-only file system - /Users/hunner/Documents/work/git/puppetlabs-apache or /vagrant/puppet/.tmp/librarian/cache/source/puppet/forge/3792e516e3ff92a0ef9f5e827f8e76eb/puppetlabs/apache/version/9eac01120a372609e0afa3b236d9ed2d/apache/spec/fixtures/modules/apache

Error: Try 'puppet help module install' for usage

/usr/lib/ruby/1.8/pathname.rb:1055:in `unlink'
: 
Directory not empty - /vagrant/puppet/.tmp/librarian/cache/source/puppet/forge/3792e516e3ff92a0ef9f5e827f8e76eb/puppetlabs/apache/version/9eac01120a372609e0afa3b236d9ed2d
 (
Errno::ENOTEMPTY
)
    from /usr/lib/ruby/1.8/pathname.rb:1055:in `unlink'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/lib/librarian/puppet/source/forge.rb:104:in `cache_version_unpacked!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/lib/librarian/puppet/source/forge.rb:48:in `install_version!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/lib/librarian/puppet/source/forge.rb:230:in `install!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/manifest.rb:89:in `install!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/install.rb:49:in `install_manifests'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/install.rb:48:in `each'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/install.rb:48:in `install_manifests'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/install.rb:39:in `perform_installation'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/action/install.rb:12:in `run'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/cli.rb:157:in `install!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/lib/librarian/puppet/cli.rb:64:in `install'
    from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
    from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
    from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
    from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
    from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
    from /var/lib/gems/1.8/gems/librarian-puppet-0.9.7/bin/librarian-puppet:9
    from /usr/local/bin/librarian-puppet:19:in `load'
    from /usr/local/bin/librarian-puppet:19

should support dependency versions of the form N.x

I have a Puppetfile that refers to a git repo that has the follow dependency set in its Modulefile

dependency 'puppetlabs/stdlib', '2.x'

I verified that this is a valid version syntax for the Modulefile.

Librarian-puppet does not seem to understand this format of version. It fails because it detects a conflict between 2.x and a version of the form 2.1.2

Ability to replace environment

It would be nice to able to specify an environment on the command line so that we can replace something like "@Environment" inside the puppetfile with whatever is passed.

Example:

mod "mymodule"
    :git => "git@git:mymodule.git",
    : path => "puppet/",
     ref => "beta",

Cannot get outdated to see git changes

Here is what I am doing.

  1. Clone a git repository into a directory idg/.

  2. Clone a git "module" repository into directory base/:

    git clone [email protected]:base.git
    
  3. Change directory into idg/ and run librarian-puppet init.

  4. Change the contents of idg/Puppetfile to

    mod 'base',
      :git => '[email protected]:base.git'
    
  5. Install the base module in `idg2/' by running

    librarian-puppet install
    
  6. Here is the output of idg/Puppetfile.lock:

    GIT
      remote: [email protected]:base.git
      ref: master
      sha: ee84ea288d27da4f5f0b1b7aedb23967c77c3df4
      specs:
        base (0.0.1)
    
    DEPENDENCIES
      base (>= 0)
    
  7. I go to base/, make a change to a file, and push that change.

  8. I go back to idg/ and type librarian-puppet outdated. There is no output.

Question: Since I made a change to the Puppet Librarian-managed module base/ and pushed that change, why does librarian-puppet outdated show no change?

Also, what does "base (0.0.1)" mean?

undefined method `manifests' for nil:NilClass (NoMethodError)

When I run librarian-puppet update --verbose, I receive the following error:

/usr/local/Cellar/ruby/1.9.3-p362/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/dependency.rb:61:in `cache_manifests!': undefined method `manifests' for nil:NilClass (NoMethodError)

It seems to be related to the following module:
https://github.com/example42/puppet-iptables

Full log:
https://gist.github.com/fieg/100818431a51dcca8b89

How do I do nested dependencies?

If I want one Puppet module to depend on another Puppet module, how can I do this with librarian-puppet?

For example: if razor depends on apt, I should only have to put the razor dependency in my Puppetfile and razor would automatically cause apt to be downloaded (much as Debian or RPM package systems work).

Dependency in module overrides Puppetfile if --verbose is used.

My Puppetfile stipulates:

mod "sudo",
  :git => "git://github.com/saz/puppet-sudo.git",
  :ref => 'master'

One of my modules has a reference to the same module:

dependency 'saz/sudo', '>= 2.0.6'

2.0.6 is saz/puppet-sudo@232845e
master is currently at saz/puppet-sudo@ac5ea21 - one commit after 2.0.6, and containing a vital bugfix to 2.0.6 which was broken and unuseable. I do not understand why this commit wasn't labelled 2.0.7.

But in any case, my problem is that puppet-librarian keeps reverting back to 2.0.6, which is not what I want.

Specifically, librarian-puppet update sudo --verbose will reset the sudo module to 2.0.6. librarian-puppet update sudo will update it to the latest commit on master.

I would expect that, given the summarised output below, the latest version that is >= 2.0.6 and also on master would always be chosen. I would not expect that "--verbose" should have any effect on what gets chosen.

Please note that I'm running 0.9.3, as #31 makes 0.9.4 completely unuseable for me.

Summarised output:

jpolley@puppetmaster:puppet$sudo librarian-puppet update --verbose | grep sudo
[Librarian]   [:git, "git://github.com/saz/puppet-sudo.git", {:ref=>"master"}]
[Librarian] Scheduling sudo (>= 0) <git://github.com/saz/puppet-sudo.git#master>
[Librarian]       Scheduling saz/sudo (>= 2.0.0) <http://forge.puppetlabs.com>
[Librarian]                                                                   Resolving sudo (>= 0) <git://github.com/saz/puppet-sudo.git#master>
[Librarian]                                                                       Checking sudo/0.0.1 <git://github.com/saz/puppet-sudo.git#master>
[Librarian]                                                                                                                               Resolving saz/sudo (>= 2.0.0) <http://forge.puppetlabs.com>
[Librarian]                                                                                                                                   Checking saz/sudo/2.0.6 <http://forge.puppetlabs.com>
[Librarian]                                                                                                                                     Resolved saz/sudo (>= 2.0.0) <http://forge.puppetlabs.com> at saz/sudo/2.0.6 <http://forge.puppetlabs.com>
[Librarian]                                                                                                                                 Resolved saz/sudo (>= 2.0.0) <http://forge.puppetlabs.com>
[Librarian]                                                                         Resolved sudo (>= 0) <git://github.com/saz/puppet-sudo.git#master> at sudo/0.0.1 <git://github.com/saz/puppet-sudo.git#master>
[Librarian]                                                                     Resolved sudo (>= 0) <git://github.com/saz/puppet-sudo.git#master>
[Librarian]   [:git, "git://github.com/saz/puppet-sudo.git", {:ref=>"master"}]
[Librarian] Installing sudo/0.0.1 <git://github.com/saz/puppet-sudo.git#master>
[Librarian] Deleting modules/sudo
[Librarian] Copying .tmp/librarian/cache/source/git/fea3c6aa476fc0e0257fdd836f83670f to modules/sudo

Does not run with Puppet 3.0.0

Using puppet version 3.0.0, librarian-puppet does not run:

root@puppet:/etc/puppet# puppet --version
3.0.0

Simple Puppetfile:

forge "http://forge.puppetlabs.com"

mod "puppetlabs/stdlib"

Output from librarian-puppet install --verbose:

[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: x86_64-linux
[Librarian] Rubygems Version: 1.8.15
[Librarian] Librarian Version: 0.0.24
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /etc/puppet
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/bin/git
[Librarian] Git Version: git version 1.7.9.5
[Librarian] Git Environment Variables:
[Librarian]   (empty)
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:forge, "http://forge.puppetlabs.com", {}]
[Librarian] Scheduling puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian] Resolving puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian]     Checking puppetlabs/stdlib/3.0.1 <http://forge.puppetlabs.com>
[Librarian]       Resolved puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com> at puppetlabs/stdlib/3.0.1 <http://forge.puppetlabs.com>
[Librarian]   Resolved puppetlabs/stdlib (>= 0) <http://forge.puppetlabs.com>
[Librarian] Bouncing Puppetfile.lock
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:forge, "http://forge.puppetlabs.com", {}]
๏ฟฝ[31mTo get modules from the forge, we use the puppet faces module command. Your current version does not support the options --target-dir,--modulepath,--ignore-dependencies . For this you need at least puppet version 2.7.13๏ฟฝ[0m
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/source/forge.rb:124:in `check_puppet_module_options'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/source/forge.rb:92:in `cache_version_unpacked!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/source/forge.rb:48:in `install_version!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/source/forge.rb:239:in `install!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/manifest.rb:89:in `install!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/install.rb:49:in `install_manifests'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/install.rb:48:in `each'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/install.rb:48:in `install_manifests'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/install.rb:39:in `perform_installation'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/action/install.rb:12:in `run'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:157:in `install!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/lib/librarian/puppet/cli.rb:64:in `install'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `send'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
/var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
/var/lib/gems/1.8/gems/librarian-puppet-0.9.6/bin/librarian-puppet:9
/usr/local/bin/librarian-puppet:19:in `load'
/usr/local/bin/librarian-puppet:19

librarian-puppet update fails with rc1 versions

The update command suffers from the malformed version number string issue similar to install. As far as I can see librarian-puppet inherits the update command directly from librarian and over-ride it like the install command does.

What seems to be the issue, is that it assumes that module versions are formatted identically to ruby gem versions, however as they are not ruby gems they don't adhere to the same strict version format. So librarian-puppet is relying on librarian to use the librarian gem version checker in manifest.rb to check versions for things that are not gems.

root@puppet:/etc/puppet# librarian-puppet update apache
/usr/lib/ruby/1.9.1/rubygems/version.rb:187:in `initialize': Malformed version number string 0.5.0-rc1 (ArgumentError)
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:12:in `new'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:12:in `initialize'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:117:in `new'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:117:in `_normalize_version'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:101:in `fetched_version'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:55:in `version'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/manifest.rb:85:in `satisfies?'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/dependency.rb:65:in `satisfied_by?'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `block (5 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `each'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `all?'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:65:in `block (4 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:64:in `block (3 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `each'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `block (2 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:59:in `block in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:42:in `recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:72:in `block (4 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:64:in `block (3 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `each'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `block (2 levels) in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:59:in `block in recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:42:in `recursive_resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver/implementation.rb:20:in `resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/resolver.rb:18:in `resolve'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/action/update.rb:22:in `run'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/cli.rb:165:in `update!'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/cli.rb:105:in `update'
        from /var/lib/gems/1.9.1/gems/thor-0.16.0/lib/thor/task.rb:27:in `run'
        from /var/lib/gems/1.9.1/gems/thor-0.16.0/lib/thor/invocation.rb:120:in `invoke_task'
        from /var/lib/gems/1.9.1/gems/thor-0.16.0/lib/thor.rb:275:in `dispatch'
        from /var/lib/gems/1.9.1/gems/thor-0.16.0/lib/thor/base.rb:425:in `start'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
        from /var/lib/gems/1.9.1/gems/librarian-puppet-maestrodev-0.9.7.2/bin/librarian-puppet:9:in `<top (required)>'
        from /usr/local/bin/librarian-puppet:23:in `load'
        from /usr/local/bin/librarian-puppet:23:in `<main>'

forces install of puppet from Gem, even when already installed from RPM

On CentOS/Scientific Linux 6.2 x64, when installing puppet-librarian it forces install of latest Puppet (currently 3.0.0) even though Puppet is already installed as an RPM.

Puppetlabs recommend use of RPM/Deb over Gem installs (http://docs.puppetlabs.com/guides/installation.html#installing-from-gems-not-recommended), and I don't want to be forced into Puppet 3.0.0 just yet.

Can something be done to stop this from happening?

Duplicate entries returns out of sync error

It's not a bug but it might save ppl some time debugging if it would just say that a module has been define twice.

$ cat Puppetfile
mod 'stdlib',                                                                    
  :git => 'git://github.com/puppetlabs/puppetlabs-stdlib.git'

mod 'stdlib',                                                                    
  :git => 'git://github.enterprise.com/puppetlabs-stdlib.git'
$ librarian-puppet install
Puppetfile and Puppetfile.lock are out of sync!

librarian-puppet clean

Wondering if it should take into account the LIBRARIAN_PUPPET_DESCTRUCTIVE setting and only delete modules that are managed by librarian-puppet.

I see the clean is an action from librarian you invoke. Doing the above would require to monkey patch the behavior. Or maybe a check first.

Thoughts?

Nasty error when a module is not found on the forge

I have the following file:

forge "http://forge.puppetlabs.com"

mod "puppetlabs/stdlib"
mod "puppetlabs/apt"
mod "puppetlabs/apache"
mod "puppetlabs/dashboard"
mod "puppetlabs/firewall"
mod "puppetlabs/gcc"
mod "puppetlabs/passenger"
mod "puppetlabs/sudo"

Due to the fact that puppetlabs/sudo does not exist on the forge I am getting the following stack trace:

vagrant@vms:~/vagrant/development-environment$ librarian-puppet install --clean
/var/lib/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/forge.rb:24:in `versions': undefined method `map' for nil:NilClass (NoMethodError)
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/forge.rb:33:in `manifests'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/forge.rb:192:in `manifests'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/dependency.rb:65:in `cache_manifests!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/dependency.rb:61:in `manifests'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:59:in `recursive_resolve'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:107:in `scope'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:46:in `recursive_resolve'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver/implementation.rb:24:in `resolve'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/resolver.rb:19:in `resolve'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/resolve.rb:25:in `run'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:139:in `resolve!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:75:in `install'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `send'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `run'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/invocation.rb:120:in `invoke_task'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor.rb:275:in `dispatch'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/base.rb:408:in `start'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:33:in `bin!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/bin/librarian-puppet:9
        from /usr/local/bin/librarian-puppet:19:in `load'
        from /usr/local/bin/librarian-puppet:19

The more modules that are required, the longer the error is.

Not switching to ref => branch

I can't seem to switch to the right branch for any module on our private Github Enterprise instance. Instead it always picks master. Not sure what I'm doing wrong. The exact same syntax works for anything on f.i. the public puppetlabs repos.

I have three modules in the example below, each containing 3 remote branches:

  • master
  • staging
  • production
ozymandias:production$ ls
Puppetfile

ozymandias:production$ cat Puppetfile 

mod 'activemq',
  :git => '[email protected]:private/pm_activemq.git',
  :ref => 'master'

mod 'aleph',
  :git => '[email protected]:private/pm_aleph.git',
  :ref => 'staging'

mod 'appl',
  :git => '[email protected]:private/pm_appl.git',
  :ref => 'origin/production'
ozymandias:production$ librarian-puppet install --verbose
[Librarian] Ruby Version: 1.8.7
[Librarian] Ruby Platform: i686-darwin11
[Librarian] Rubygems Version: 1.8.13
[Librarian] Librarian Version: 0.0.23
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /Users/tom/tmp/modules/env/production
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/local/bin/git
[Librarian] Git Version: git version 1.7.9.2
[Librarian] Git Environment Variables:
[Librarian]   GIT_PS1_SHOWDIRTYSTATE=true
[Librarian]   GIT_PS1_SHOWUNTRACKEDFILES=true
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "[email protected]:private/pm_aleph.git", {:ref=>"origin/staging"}]
[Librarian]   [:git, "[email protected]:private/pm_appl.git", {:ref=>"origin/production"}]
[Librarian]   [:git, "[email protected]:private/pm_activemq.git", {:ref=>"master"}]
[Librarian] Scheduling activemq (>= 0) <[email protected]:private/pm_activemq.git#master>
[Librarian] Scheduling aleph (>= 0) <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian] Scheduling appl (>= 0) <[email protected]:private/pm_appl.git#origin/production>
[Librarian] Resolving activemq (>= 0) <[email protected]:private/pm_activemq.git#master>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian] Running `/usr/local/bin/git clone [email protected]:private/pm_activemq.git . --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> c7f891a7ada69aef36eec746e080a2150eacec67
[Librarian] Running `/usr/local/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git remote` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> origin
[Librarian] Running `/usr/local/bin/git branch -r` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian]     -->   origin/production
[Librarian]     -->   origin/staging
[Librarian] Running `/usr/local/bin/git rev-parse origin/master --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> c7f891a7ada69aef36eec746e080a2150eacec67
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> c7f891a7ada69aef36eec746e080a2150eacec67
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> c7f891a7ada69aef36eec746e080a2150eacec67
[Librarian]     Checking activemq/0.0.1 <[email protected]:private/pm_activemq.git#master>
[Librarian]       Resolving aleph (>= 0) <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian]         No known prior constraints
[Librarian]         Checking manifests
[Librarian] Running `/usr/local/bin/git clone [email protected]:private/pm_aleph.git . --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> 375dd155a776597779c88fd744cefc3690b69c1d
[Librarian] Running `/usr/local/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git remote` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> origin
[Librarian] Running `/usr/local/bin/git branch -r` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian]     -->   origin/production
[Librarian]     -->   origin/staging
[Librarian] Running `/usr/local/bin/git rev-parse origin/staging --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> 375dd155a776597779c88fd744cefc3690b69c1d
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> 375dd155a776597779c88fd744cefc3690b69c1d
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> 375dd155a776597779c88fd744cefc3690b69c1d
[Librarian]           Checking aleph/0.0.1 <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian]             Resolving appl (>= 0) <[email protected]:private/pm_appl.git#origin/production>
[Librarian]               No known prior constraints
[Librarian]               Checking manifests
[Librarian] Running `/usr/local/bin/git clone [email protected]:private/pm_appl.git . --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> 4025cea766de152a8417dc69d4ec25382594a785
[Librarian] Running `/usr/local/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git remote` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> origin
[Librarian] Running `/usr/local/bin/git branch -r` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/master
[Librarian]     -->   origin/production
[Librarian]     -->   origin/staging
[Librarian] Running `/usr/local/bin/git rev-parse origin/production --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> 4025cea766de152a8417dc69d4ec25382594a785
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> 4025cea766de152a8417dc69d4ec25382594a785
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> 4025cea766de152a8417dc69d4ec25382594a785
[Librarian]                 Checking appl/0.0.1 <[email protected]:private/pm_appl.git#origin/production>
[Librarian]                   Resolved appl (>= 0) <[email protected]:private/pm_appl.git#origin/production> at appl/0.0.1 <[email protected]:private/pm_appl.git#origin/production>
[Librarian]               Resolved appl (>= 0) <[email protected]:private/pm_appl.git#origin/production>
[Librarian]             Resolved aleph (>= 0) <[email protected]:private/pm_aleph.git#origin/staging> at aleph/0.0.1 <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian]         Resolved aleph (>= 0) <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian]       Resolved activemq (>= 0) <[email protected]:private/pm_activemq.git#master> at activemq/0.0.1 <[email protected]:private/pm_activemq.git#master>
[Librarian]   Resolved activemq (>= 0) <[email protected]:private/pm_activemq.git#master>
[Librarian] Bouncing Puppetfile.lock
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "[email protected]:private/pm_aleph.git", {:ref=>"origin/staging"}]
[Librarian]   [:git, "[email protected]:private/pm_appl.git", {:ref=>"origin/production"}]
[Librarian]   [:git, "[email protected]:private/pm_activemq.git", {:ref=>"master"}]
[Librarian] Installing appl/0.0.1 <[email protected]:private/pm_appl.git#origin/production>
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b
[Librarian]     --> 4025cea766de152a8417dc69d4ec25382594a785
[Librarian] Copying .tmp/librarian/cache/source/git/cbb489a59d8f392af6b1c9d1052f038b to modules/appl
[Librarian] Installing aleph/0.0.1 <[email protected]:private/pm_aleph.git#origin/staging>
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0
[Librarian]     --> 375dd155a776597779c88fd744cefc3690b69c1d
[Librarian] Copying .tmp/librarian/cache/source/git/c67bda00386ab775d5c193d1ee0c26b0 to modules/aleph
[Librarian] Installing activemq/0.0.1 <[email protected]:private/pm_activemq.git#master>
[Librarian] Running `/usr/local/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --- No output
[Librarian] Running `/usr/local/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb
[Librarian]     --> c7f891a7ada69aef36eec746e080a2150eacec67
[Librarian] Copying .tmp/librarian/cache/source/git/975e51fdfaab636eeadf90f33bf8ebcb to modules/activemq
ozymandias:production$ cd modules/activemq/
ozymandias:activemq(git:master)$ git branch   
* master
ozymandias:activemq(git:master)$ git branch -r
  origin/HEAD -> origin/master
  origin/master
  origin/production
  origin/staging
ozymandias:activemq(git:master)$ cd ../aleph/
ozymandias:aleph(git:master)$ git branch 
* master
ozymandias:aleph(git:master)$ git branch -r
  origin/HEAD -> origin/master
  origin/master
  origin/production
  origin/staging
ozymandias:aleph(git:master)$ cd ../appl/
ozymandias:appl(git:master)$ git branch 
* master
ozymandias:appl(git:master)$ git branch -r
  origin/HEAD -> origin/master
  origin/master
  origin/production
  origin/staging

Rake problem?

Added a new repo to my list, only get this error when its added:

mod 'puppet-users',
:git => 'https://github.com/rhysrhaven/puppet-users.git'

root@puppetmaster:/etc/puppet# librarian-puppet update
/usr/lib/ruby/1.8/fileutils.rb:1414:in fu_each_src_dest0': undefined methodto_str' for nil:NilClass (NoMethodError)
from /usr/lib/ruby/1.8/fileutils.rb:1400:in fu_each_src_dest' from /usr/lib/ruby/1.8/fileutils.rb:423:incp_r'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/lib/librarian/puppet/source/local.rb:43:in install_perform_step_copy!' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/lib/librarian/puppet/source/local.rb:26:ininstall!'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/manifest.rb:89:in install!' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/install.rb:49:ininstall_manifests'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/install.rb:48:in each' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/install.rb:48:ininstall_manifests'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/install.rb:39:in perform_installation' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/action/install.rb:12:inrun'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/cli.rb:157:in install!' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/cli.rb:107:inupdate'
from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:in send' from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/task.rb:27:inrun'
from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/invocation.rb:120:in invoke_task' from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor.rb:275:indispatch'
from /var/lib/gems/1.8/gems/thor-0.16.0/lib/thor/base.rb:425:in start' from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/vendor/librarian/lib/librarian/cli.rb:29:inbin!'
from /var/lib/gems/1.8/gems/librarian-puppet-0.9.4/bin/librarian-puppet:9
from /usr/local/bin/librarian-puppet:19:in `load'
from /usr/local/bin/librarian-puppet:19

Possibly seems to be this? https://groups.google.com/d/topic/hobousers/YlBRARMR380/discussion
Not a ruby dev so this only makes as much sense as "sounds like a scoping problem?"

--strip-dot-git doesn't appear to work

While running 'librarian-puppet install --strip-dot-git' will install Puppet modules properly, and set a flag in .librarian/config, it doesn't appear to actually do anything. Since it's also not documented in the readme, I'm not sure of the proper usage or functionality. My supposition is that calling it as above would remove the .git directories from the Puppet modules downloaded via Git. However, they remain.

master looks up Puppetfile from home directory

Hi Tim,

I just pulled master from librarian-puppet and I got the following error:

/Users/danbode/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/pathname.rb:770:in `read': No such file or directory - /Users/danbode/Puppetfile (Errno::ENOENT)

Did this behavior change? Is it not looking form Puppetfile in its current path?

librarian-puppet does not respect $http_proxy

librarian-puppet does not listen to my $http_proxy variable. I need to access forge.puppetlabs.net from a host that does not have direct internet access. I have fixed the issue and am submitting a patch.

Cannot detect puppet installed from rpm

[root@localhost puppet]# librarian-puppet install --verbose
Unable to load puppet. Either install it using native packages for your
platform (eg .deb, .rpm, .dmg, etc) or as a gem (gem install puppet).

[root@localhost puppet]# gem list

*** LOCAL GEMS ***

json (1.7.7)
json_pure (1.7.7)
librarian-puppet (0.9.8)
thor (0.17.0)

[root@localhost puppet]# rpm -qa | grep -i puppet
puppet-3.1.0-1.el5
puppetlabs-release-5-6

[root@localhost puppet]# puppet help
Usage: puppet [options] [options]

Available subcommands:

agent The puppet agent daemon
apply Apply Puppet manifests locally
ca Local Puppet Certificate Authority management.
....

Dependencies do not resolve?

I installed librarian-puppet 0.9.7, created an empty directory at /tmp/bleh and ran librarian-puppet init.

I'm unable to install any modules, possibly due to the 0.0.x nomenclature? I'm not sure, here's the verbose output:

http://pastie.org/5069739

Version range is not parsed correctly

In our Puppetfile we currently have (among others)

mod "postgresql",
  :git => "git://github.com/puppetlabs/puppet-postgresql.git"

When running librarian-puppet install we get:

/opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:81:in `parse': Illformed requirement [">=3.2.0 <4.0.0"] (ArgumentError)
    from /opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:106:in `block in initialize'
    from /opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:106:in `map!'
    from /opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:106:in `initialize'
    from /opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:47:in `new'
    from /opt/bw/lib/ruby/1.9.1/rubygems/requirement.rb:47:in `create'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/dependency.rb:10:in `initialize'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/dependency.rb:50:in `new'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/dependency.rb:50:in `initialize'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/lib/librarian/puppet/source/git.rb:103:in `new'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/lib/librarian/puppet/source/git.rb:103:in `block in fetch_dependencies'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/lib/librarian/puppet/source/git.rb:102:in `each'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/lib/librarian/puppet/source/git.rb:102:in `map'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/lib/librarian/puppet/source/git.rb:102:in `fetch_dependencies'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:113:in `fetch_dependencies!'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:105:in `fetched_dependencies'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/manifest.rb:69:in `dependencies'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:67:in `block (4 levels) in recursive_resolve'
    from /opt/bw/lib/ruby/gems/1.9.1/gems/librarian-puppet-0.9.8/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
....

puppetlabs-postgres/Modulefile contains a range: dependency 'puppetlabs/stdlib', '>=3.2.0 <4.0.0', which seems to make librarian stumble.

This however, is correct syntax, according to http://docs.puppetlabs.com/puppet/3/reference/modules_publishing.html#dependencies-in-the-modulefile

When trying to install puppetlabs-sudo using git an error occours

I have the following Puppetfile:

forge "http://forge.puppetlabs.com"

mod "puppetlabs/stdlib"
mod "puppetlabs/apt"
mod "puppetlabs/apache"
mod "puppetlabs/dashboard"
mod "puppetlabs/firewall"
mod "puppetlabs/gcc"
mod "puppetlabs/passenger"
mod "puppetlabs/sudo",
    :git => "git://github.com/puppetlabs/puppetlabs-sudo.git"

And I am getting this stack trace:

vagrant@vms:~/vagrant/development-environment$ sudo librarian-puppet install --clean
/usr/lib/ruby/1.8/fileutils.rb:1241:in `mkdir': No such file or directory - /home/vagrant/vagrant/development-environment/modules/puppetlabs/sudo (Errno::ENOENT)
        from /usr/lib/ruby/1.8/fileutils.rb:1241:in `copy'
        from /usr/lib/ruby/1.8/fileutils.rb:452:in `copy_entry'
        from /usr/lib/ruby/1.8/fileutils.rb:1331:in `traverse'
        from /usr/lib/ruby/1.8/fileutils.rb:449:in `copy_entry'
        from /usr/lib/ruby/1.8/fileutils.rb:424:in `cp_r'
        from /usr/lib/ruby/1.8/fileutils.rb:1402:in `fu_each_src_dest'
        from /usr/lib/ruby/1.8/fileutils.rb:1418:in `fu_each_src_dest0'
        from /usr/lib/ruby/1.8/fileutils.rb:1400:in `fu_each_src_dest'
        from /usr/lib/ruby/1.8/fileutils.rb:423:in `cp_r'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:37:in `install_perform_step_copy!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/lib/librarian/puppet/source/local.rb:20:in `install!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/manifest.rb:97:in `install!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:49:in `install_manifests'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:48:in `each'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:48:in `install_manifests'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:39:in `perform_installation'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/action/install.rb:12:in `run'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:135:in `install!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:76:in `install'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `send'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/task.rb:27:in `run'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/invocation.rb:120:in `invoke_task'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor.rb:275:in `dispatch'
        from /var/lib/gems/1.8/gems/thor-0.15.2/lib/thor/base.rb:408:in `start'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/vendor/librarian/lib/librarian/cli.rb:33:in `bin!'
        from /var/lib/gems/1.8/gems/librarian-puppet-0.9.0/bin/librarian-puppet:9
        from /usr/local/bin/librarian-puppet:19:in `load'
        from /usr/local/bin/librarian-puppet:19

install in 0.9.2 breaks when a module has deps set in Modulefile

If you have a module listed in your Puppetfile that has it's own Modulefile that lists some deps, librarian-puppet tries to resolve these but bombs out with the following:

lunix@glenmorangie] -> cat Puppetfile 
mod "apt",
  :git => "git://github.com/puppetlabs/puppetlabs-apt.git"
lunix@glenmorangie] -> librarian-puppet install --verbose
[Librarian] Ruby Version: 1.9.2
[Librarian] Ruby Platform: x86_64-linux
[Librarian] Rubygems Version: 1.8.6
[Librarian] Librarian Version: 0.0.24
[Librarian] Librarian Adapter: puppet
[Librarian] Project: /home/lunix/puppet/prototypes/librarian/librarian-test
[Librarian] Specfile: Puppetfile
[Librarian] Lockfile: Puppetfile.lock
[Librarian] Git: /usr/bin/git
[Librarian] Git Version: git version 1.7.10.2
[Librarian] Git Environment Variables:
[Librarian]   (empty)
[Librarian] Pre-Cached Sources:
[Librarian] Post-Cached Sources:
[Librarian]   [:git, "git://github.com/puppetlabs/puppetlabs-apt.git", {}]
[Librarian] Scheduling apt (>= 0) <git://github.com/puppetlabs/puppetlabs-apt.git#master>
[Librarian] Resolving apt (>= 0) <git://github.com/puppetlabs/puppetlabs-apt.git#master>
[Librarian]   No known prior constraints
[Librarian]   Checking manifests
[Librarian] Running `/usr/bin/git clone git://github.com/puppetlabs/puppetlabs-apt.git . --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git reset --hard --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git clean -x -d --force --force` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --> 710b1c6a665bf5f65dc93de405bdfffa9e5a59de
[Librarian] Running `/usr/bin/git fetch origin --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git fetch origin --quiet --tags` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --- No output
[Librarian] Running `/usr/bin/git remote` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --> origin
[Librarian] Running `/usr/bin/git branch -r` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     -->   origin/HEAD -> origin/master
[Librarian]     -->   origin/feature/master/dans_refactor
[Librarian]     -->   origin/master
[Librarian] Running `/usr/bin/git rev-parse origin/master^{commit} --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --> 710b1c6a665bf5f65dc93de405bdfffa9e5a59de
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --> 710b1c6a665bf5f65dc93de405bdfffa9e5a59de
[Librarian] Running `/usr/bin/git rev-parse HEAD --quiet` in .tmp/librarian/cache/source/git/a84e2bcd8551c884cd2669876ab83922
[Librarian]     --> 710b1c6a665bf5f65dc93de405bdfffa9e5a59de
[Librarian]     Checking apt/0.0.1 <git://github.com/puppetlabs/puppetlabs-apt.git#master>
[Librarian]       Scheduling puppetlabs/stdlib (>= 2.2.1) <>
[Librarian]       Resolving puppetlabs/stdlib (>= 2.2.1) <>
[Librarian]         No known prior constraints
/home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/dependency.rb:61:in `cache_manifests!': undefined method `manifests' for nil:NilClass (NoMethodError)
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/dependency.rb:57:in `manifests'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:55:in `block in recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:42:in `recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:72:in `block (4 levels) in recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:64:in `block (3 levels) in recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `each'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:60:in `block (2 levels) in recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:59:in `block in recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:103:in `scope'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:42:in `recursive_resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver/implementation.rb:20:in `resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/resolver.rb:18:in `resolve'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/action/resolve.rb:25:in `run'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/cli.rb:161:in `resolve!'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/lib/librarian/puppet/cli.rb:59:in `install'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/thor-0.15.4/lib/thor/task.rb:27:in `run'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/thor-0.15.4/lib/thor/invocation.rb:120:in `invoke_task'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/thor-0.15.4/lib/thor.rb:275:in `dispatch'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/thor-0.15.4/lib/thor/base.rb:425:in `start'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/vendor/librarian/lib/librarian/cli.rb:29:in `bin!'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/gems/librarian-puppet-0.9.2/bin/librarian-puppet:9:in `<top (required)>'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/bin/librarian-puppet:19:in `load'
    from /home/lunix/.rvm/gems/ruby-1.9.2-p290/bin/librarian-puppet:19:in `<main>'

forge.rb does not work behind a proxy

Summary

/lib/librarian/puppet/source/forge.rb needs to be updated to work behind proxies. def stream and def api_call are the two locations that I've identified.

I recommend following the pattern that was added to librarian v0.0.25 and v0.0.26. Please see their changelog for details. Obviously this also means that librarian-puppet needs to update its internal copy of librarian to also be at least v0.0.26.

Other Thoughts

My organization would very much like to use librarian-puppet. Is there anything I can do to expedite these improvments? I'd rather not have us using something that's diverged or hacked up just so it works.

More Details

Using :git instead of a forge works unless the module you are pulling down references forge.puppetlabs.com. Then forge.rb takes over for the dependencies and cannot connect. For example:

forge 'http://forge.puppetlabs.com'

mod 'apache',
   :git => 'https://github.com/puppetlabs/puppetlabs-apache.git',
   :ref => '0.4.0'

Sample hacked up snippet that worked

This was done using v0.0.26 of librarian
forge.rb -> def api_call

def api_call(path)
    base_url = source.to_s
    proxy = Net::HTTP::Proxy('my.proxy.url.com', 80)
    resp = proxy.get_response(URI.parse("#{base_url}/#{path}"))
    # resp = Net::HTTP.get_response(URI.parse("#{base_url}/#{path}"))
    if resp.code.to_i != 200
        nil
    else
        data = resp.body
        JSON.parse(data)
    end
end

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.