Issue #21654 has been updated by Charlie Sharpsteen.

Status changed from Unreviewed to Duplicate
Assignee set to Charlie Sharpsteen

Thank for reporting this. In the future you can wrap blocks of code/terminal 
output in `<pre>` / `</pre>` tags to preserve formatting.

This particular issue is a duplicate of #14652. Currently, when a resource 
requires its self, Puppet will silently ignore that Resource. The good news is 
that a fix for this bug has been merged and will be released in 3.3.0.

----------------------------------------
Bug #21654: No cyclic error?
https://projects.puppetlabs.com/issues/21654#change-94248

* Author: Douglas Garstang
* Status: Duplicate
* Priority: Normal
* Assignee: Charlie Sharpsteen
* Category: 
* Target version: 
* Affected Puppet version: 
* Keywords: 
* Branch: 
----------------------------------------
The following manifest, run locally, has two issues.

1. User repo requires User['repo'], and no error is raised.
2. Due to (1), the /truth/repo directory never gets created. Replace the 
require => User['repo'] with require => Group['repo'] and the /truth/repo 
directory gets created.

<pre>
class truth {

    group {
        'repo':
            gid => 20000,
            ensure => present;
    }

    user {
        'repo':
            uid => 20000,
            gid => 20000,
            require => User['repo'],
            ensure => present;
            
    }

    file {
        '/truth':
            ensure => directory,
            owner => 'root',
            group => 'root',
            mode => '0755';
    }

    exec {
        'truth-fs':
            command => '/sbin/mkfs -F -t ext4 /dev/sdb',
            refreshonly => true;
    }

    mount {
        '/truth':
            ensure  => mounted,
            device  => '/dev/sdb',
            fstype  => 'ext4',
            options => 'defaults,noatime,nosuid,nodev,noexec',
            pass    => 0,
            dump    => 0,
            subscribe => Exec['truth-fs'],
            require => [ Exec['truth-fs'],
                         File['/truth'] ];
    }

    file {
        '/truth/repo':
            ensure => directory,
            owner  => 'repo',
            group  => 'repo',
#            subscribe => Mount['/truth'],
#            require => [ User['repo'],
#                         Mount['/truth'] ];

    }

}

include truth
</pre>

Versions:
<pre>
root@truth16-us4:~# dpkg -l | grep puppet 
ii  facter                          1.7.1-1puppetlabs1        amd64        Ruby 
module for collecting simple facts about a host operating system
ii  hiera                           1.2.1-1puppetlabs1        all          A 
simple pluggable Hierarchical Database.
ii  puppet                          3.2.2-1puppetlabs1        all          
Centralized configuration management - agent startup and compatibility scripts
ii  puppet-common                   3.2.2-1puppetlabs1        all          
Centralized configuration management
ii  puppetlabs-release              1.0-7                     all          
"Package to install Puppet Labs gpg key and apt repo"
ii  ruby-rgen                       0.6.5-1puppetlabs1        all          A 
framework supporting Model Driven Software Development (MDSD)
</pre>

Run with:
<pre>
puppet apply manifest.pp --debug
</pre>




-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to