[Puppet Users] Dependency Cycle with puppetlabs-mrepo
Hi, I'm gettinng a dependency cycle when using PE 2.7, puppetlabs::mrepo, "role classes" and hiera : I'm trying to mirror RHN repos : # ROLE CLASS > class site::yum_repository{ > > $repos = hiera('site::yum_repository::repos') > create_resources(mrepo::repo::rhn, $repos) > } > # HIERA DEFAULTS > mrepo::params::src_root: '/srv/mrepo' > mrepo::params::www_root: '/srv/www/mrepo' > mrepo::params::user: 'apache' > mrepo::params::group : 'apache' > mrepo::params::mailto : 'UNSET' > mrepo::params::source : 'package' > mrepo::params::selinux : false > mrepo::params::rhn : true > mrepo::params::rhn_username: 'user' > mrepo::params::rhn_password: 'pass' > # NODE-SPECIFIC HIERA VALUES > mrepo::params::src_root: '/srv/mrepo' > mrepo::params::www_root: '/srv/www/mrepo' > mrepo::params::user: 'apache' > mrepo::params::group : 'apache' > mrepo::params::source : 'package' > mrepo::params::rhn : true > mrepo::params::rhn_username: 'mytrueaccount' > mrepo::params::rhn_password: 'mytruepassword' > mrepo::params::selinux : false > > # Repositories yumrepo > site::yum_repository::repos: > "rhel6-x86_64": > ensure : present > update : 'now' > arch : 'x86_64' > release: '6' > rhnrelease : '6Server' > repotitle : 'RHEL 6.3 64 Bits' > urls : > rhn-tools : 'rhns:///rhn-tools-rhel-$arch-server-6' And I use the dashboard as an ENC to attach the site::yum_repository class to the node puppet-node. When I'm trying to run a *puppet agent --test* I got the following output : *err: Could not apply complete catalog: Found 1 dependency cycle:* *(File[/srv/www/mrepo] => File[10-mrepo.conf] => Service[httpd] => Class[Apache] => File[/srv/www/mrepo])* *Cycle graph written to /var/opt/lib/pe-puppet/state/graphs/cycles.dot.* Any lead on what's wrong in my manifests or on how to debug the dependency cycle ? Thanks for your help, Benoit BARTHELEMY -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/zOj3_eIidJIJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
[Puppet Users] Re: Dependency Cycle with puppetlabs-mrepo
Correction, the class is the following : class site::yum_repository{ class{'mrepo::params': src_root => hiera('mrepo::params::src_root'), www_root => hiera('mrepo::params::www_root'), user => hiera('mrepo::params::user'), group=> hiera('mrepo::params::group'), source => hiera('mrepo::params::source'), selinux => hiera('mrepo::params::selinux'), rhn => hiera('mrepo::params::rhn'), rhn_username => hiera('mrepo::params::rhn_username'), rhn_password => hiera('mrepo::params::rhn_password'), mailto => hiera('mrepo::params::mailto') } $repos = hiera('site::yum_repository::repos') create_resources(mrepo::repo::rhn, $repos) } -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/vrGcE6x5VJsJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
[Puppet Users] Re: Dependency Cycle with puppetlabs-mrepo
Hi Adrien, I'm using the version of the puppet forge (1.1.0), I've had most difficulties to make it work on RHEL 6 to mirror RHN repos... - There is a test in manifest/rhn.pp that evaluates if the server is Centos to create missing ressources, in fact those values are absent from RHEL6 as well. - The server is behind a proxy, it's not supported in the current forge module (had to hack the Exec ressource in manifest/repo/rhn to add environment variable http_proxy). - If the /var/log/up2date file is not writable (it's not managed by , the module tries to write it's log in /root/up2date. - I think I've managed to find where the cycle is : manifest/webservice.pp => the docroot require Apache, the apache::vhost require the docroot and trigger an Apache refresh... All on the same stage : Class['apache'] -> File['$docroot'] -> Apache::Vhost['mrepo'] ~> Service['Apache'] = cycle (as Class['apache'] -> Service['Apache']. I've removed the dependency Class['apache'] -> File['$docroot']. - Finally I've added this to site::yum_repository : Class['apache'] -> Class['mrepo::params'] -> Mrepo::Repo::Rhn<||> I've not found any new version on github so I may have used the module incorrectly... Regards, Benoit BARTHELEMY ( Le jeudi 24 janvier 2013 22:48:26 UTC+1, Adrien Thebo a écrit : > > Hi Benoit, > > I'm the author of the puppetlabs-mrepo module, what version of this module > are you using? > > On Thursday, January 24, 2013 12:16:05 AM UTC-8, Benoit BARTHELEMY wrote: >> >> Hi, I'm gettinng a dependency cycle when using PE 2.7, puppetlabs::mrepo, >> "role classes" and hiera : >> >> I'm trying to mirror RHN repos : >> >> # ROLE CLASS >> >>> class site::yum_repository{ >>> >>> $repos = hiera('site::yum_repository::repos') >>> create_resources(mrepo::repo::rhn, $repos) >>> } >>> >> >> # HIERA DEFAULTS >> >>> mrepo::params::src_root: '/srv/mrepo' >>> mrepo::params::www_root: '/srv/www/mrepo' >>> mrepo::params::user: 'apache' >>> mrepo::params::group : 'apache' >>> mrepo::params::mailto : 'UNSET' >>> mrepo::params::source : 'package' >>> mrepo::params::selinux : false >>> mrepo::params::rhn : true >>> mrepo::params::rhn_username: 'user' >>> mrepo::params::rhn_password: 'pass' >>> >> >> >> # NODE-SPECIFIC HIERA VALUES >> >>> mrepo::params::src_root: '/srv/mrepo' >>> mrepo::params::www_root: '/srv/www/mrepo' >>> mrepo::params::user: 'apache' >>> mrepo::params::group : 'apache' >>> mrepo::params::source : 'package' >>> mrepo::params::rhn : true >>> mrepo::params::rhn_username: 'mytrueaccount' >>> mrepo::params::rhn_password: 'mytruepassword' >>> mrepo::params::selinux : false >>> >>> # Repositories yumrepo >>> site::yum_repository::repos: >>> "rhel6-x86_64": >>> ensure : present >>> update : 'now' >>> arch : 'x86_64' >>> release: '6' >>> rhnrelease : '6Server' >>> repotitle : 'RHEL 6.3 64 Bits' >>> urls : >>> rhn-tools : 'rhns:///rhn-tools-rhel-$arch-server-6' >> >> >> And I use the dashboard as an ENC to attach the site::yum_repository >> class to the node puppet-node. >> >> When I'm trying to run a *puppet agent --test* I got >> the following output : >> >> *err: Could not apply complete catalog: Found 1 dependency cycle:* >> *(File[/srv/www/mrepo] => File[10-mrepo.conf] => Service[httpd] => >> Class[Apache] => File[/srv/www/mrepo])* >> *Cycle graph written to /var/opt/lib/pe-puppet/state/graphs/cycles.dot.* >> >> Any lead on what's wrong in my manifests or on how to debug the >> dependency cycle ? >> >> Thanks for your help, >> >> Benoit BARTHELEMY >> > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Re: Coordinated application deployments
Why don't you use nodes groups or environments to prevent the second set of servers to be updated? Once validated on the first node group, you can easily deploy on the second set. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To post to this group, send email to puppet-users@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Re: Coordinated application deployments
Why don't you use nodes groups or environments to prevent the second set of servers to be updated? Once validated on the first node group, you can easily deploy on the second set. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To post to this group, send email to puppet-users@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [Puppet Users] Re: Coordinated application deployments
Sorry wrong thread *getting more coffee* -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To post to this group, send email to puppet-users@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[Puppet Users] PE VMware VM deployment (localization problem)
Hi Guys ! I'm currently evaluating Puppet's cloud provisioner on vmWARE. I think I just ran into a silly localisation problem : [root@puppet ~]# puppet node_vmware list > notice: Connecting ... > notice: Connected to myVcenter as Puppet (API version 4.1) > notice: Finding all Virtual Machines ... (Started at 10:30:37 AM) > notice: Control will be returned to you in 10 minutes at 10:40 AM if > locating is unfinished. > Locating: 100% |oo| Time: > 00:00:00 > notice: Complete > /Centres de données/myCluster/vm/Modeles/Linux/mymodel > powerstate: poweredOff > [...] > template: true > > puppet node_vmware create --name=deploy_puppet --template="/Centres de > données/myCluster/vm/Modeles/Linux/mymodel" > err: The --template option must be a path, for example > /Datacenters/Solutions/vm/templates/puppet_template. > err: Try 'puppet help node_vmware create' for usage > I think the french translation of vCenter is messing up with fog, anyone experiencing the same issue ? Regards, Benoit BARTHELEMY -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/s5bGi3N_gOoJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.