Local Module installation via r10k - puppet ....Help Needed

266 views
Skip to first unread message

Vijayabalan Balakrishnan

unread,
May 12, 2015, 11:35:17 AM5/12/15
to puppet...@googlegroups.com
I have configured the puppet PE 3.8 and sucessfully integrated r10k and git.I am able to download modules from forgeapi.puppetlabs.com and i can able to populate via r10k for dynamic branches.

Now i have downloaded some modules from forgeapi.puppetlabs.com and kept it to /modules directory

my Puppetfile is like below....

mod 'puppetlabs/apache', :path => '/module/apache'
mod 'puppetlabs/vsftpd', :path => '/module/vsftpd'
mod 'puppetlabs/portage', :path => '/modules/portage'
mod 'puppetlabs/pe_gem', :path => '/modules/pe_gem'
mod 'puppetlabs/vcsrepo', :path => '/modules/vcsrepo'
mod 'puppetlabs/ntp', :path => '/modules/ntp'
mod 'puppetlabs/inifile', :path => '/modules/inifile'
mod 'puppetlabs/mysql', :path => '/modules/mysql'
mod 'puppetlabs/postgresql', :path => '/modules/postgresql'
mod 'puppetlabs/firewall', :path => '/modules/firewall'
mod 'puppetlabs/puppetdb', :path => '/modules/puppetdb'
mod 'puppetlabs/concat', :path => '/modules/concat'
mod 'puppetlabs/stdlib', :path => '/modules/stdlib'

when i execute the following command i am getting the below error

r10k deploy environment -pv

INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/apache
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/vsftpd
ERROR    -> Command exited with non-zero exit code:
Command: puppet module --modulepath /etc/puppetlabs/puppet/environments/operations_vijay/modules --color false install --force puppetlabs/vsftpd
Stdout:
Notice: Preparing to install into /etc/puppetlabs/puppet/environments/operations_vijay/modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Stderr:
Error: Could not install 'puppetlabs-vsftpd' (latest)
  No releases are available from https://forgeapi.puppetlabs.com
    Does 'puppetlabs-vsftpd' have at least one published release?
Exit code: 1
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/portage
ERROR    -> Command exited with non-zero exit code:
Command: puppet module --modulepath /etc/puppetlabs/puppet/environments/operations_vijay/modules --color false install --force puppetlabs/portage
Stdout:
Notice: Preparing to install into /etc/puppetlabs/puppet/environments/operations_vijay/modules ...
Notice: Downloading from https://forgeapi.puppetlabs.com ...
Stderr:
Error: Could not install 'puppetlabs-portage' (latest)
  No releases are available from https://forgeapi.puppetlabs.com
    Does 'puppetlabs-portage' have at least one published release?
Exit code: 1
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/pe_gem
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/vcsrepo
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/ntp
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/inifile
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/mysql
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/postgresql
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/firewall
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/puppetdb
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/concat
INFO     -> Deploying module /etc/puppetlabs/puppet/environments/operations_vijay/modules/stdlib
INFO     -> Removing unmanaged path /etc/puppetlabs/puppet/environments/production



from this output i dont understand why still trying to  download from internet rather than /modules directory....


Please advise me on this......

Vijayabalan Balakrishnan

unread,
May 12, 2015, 3:57:58 PM5/12/15
to puppet...@googlegroups.com
-bash-4.1$ r10k deploy environment -pv
INFO     -> Deploying environment /etc/puppetlabs/puppet/environments/operation_production
INFO     -> Deploying environment /etc/puppetlabs/puppet/environments/operation_vijay


[root@ puppet]# ls -ltrh /etc/puppetlabs/puppet/environments/operation_vijay/modules/
total 0

No modules are listed..

Kindly help me.....

Anderson Mills

unread,
May 13, 2015, 5:34:15 PM5/13/15
to puppet...@googlegroups.com
Vijayabalan,

So the Puppetfile for r10k is not the same as for Librarian-puppet, and there is no :path key for a mod in r10k.

You'll either have to keep them in a repo and specify a :git key, or pull them from the forge.

Docs for r10k's use of Puppetfile! https://docs.puppetlabs.com/pe/latest/r10k_puppetfile.html
(The docs are for PE 3.8, but r10k is the same between Puppet Enterprise and open source.)

This is also an issue that is on the roadmap -- https://github.com/puppetlabs/r10k/issues/47

Hope that helps,
Anderson
Reply all
Reply to author
Forward
0 new messages