Como você instala automaticamente módulos de fantoches em 'puppet apply'?

7

É possível instalar ou incluir automaticamente módulos de fantoches na sua configuração de fantoches? Estou tendo que executar manualmente puppet module install antes de executar puppet apply .

    
por Mike 29.06.2013 / 01:34

3 respostas

3

Estou baixando módulos e armazenando-os em um diretório acima do meu Vagrantfile , no qual especifiquei o caminho para encontrar módulos usando config.vm.provision :puppet, :module_path => "modules" e, em seguida, incluí-los no meu manifesto de fantoches.

    
por 18.07.2013 / 09:53
1

AFAIK não é possível com 'vanilla' Puppet, mas com bibliotecário-fantoche é possível:

Librarian-puppet is a bundler for your puppet infrastructure. You can use librarian-puppet to manage the puppet modules your infrastructure depends on. It is based on Librarian, a framework for writing bundlers, which are tools that resolve, fetch, install, and isolate a project's dependencies.

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.

    
por 08.07.2013 / 22:47
0

Por enquanto, Vagrant tem o módulo vagrant-librarian-puppet .

Instalação:

vagrant plugin install vagrant-librarian-puppet

Do readme:

Vagrant will automatically run Librarian-Puppet before any provisioning step, so simply set up your Puppetfile as you normally would.

You may specify the subdirectory within which to run librarian-puppet using the librarian_puppet.puppetfile_dir config key. Please keep in mind that you will need to explicitly set the modules path in the :puppet provisioner and this path must exist before running vagrant commands.

    
por 14.09.2014 / 00:55