David Portabella
2014-Mar-19 12:54 UTC
[Puppet Users] i require a defined type which contains a file resource, but the file resource does not retain the relatioship
I have this test.pp example on puppet 3.4.3 on OSX 10.9: c2 {'test': } -> c3 {'test': } define c1 { notice "+++" file {'/tmp/c1.txt': ensure => present } } define c2 { c1 {$name: } notice "+++" file {'/tmp/c2.txt': ensure => present } } define c3 { notice "+++" file {'/tmp/c3.txt': ensure => present } } running: $ puppet apply --graph test.pp produces this graph /Users/david/.puppet/var/state/graphs/relationships.dot, *which shows that /tmp/c3.txt does not require /tmp/c2.txt.* *why?* digraph Relationships { label = "Relationships" "Stage[main]" [ fontsize = 8, label = "Stage[main]" ] "Class[Settings]" [ fontsize = 8, label = "Class[Settings]" ] "Class[Main]" [ fontsize = 8, label = "Class[Main]" ] "C2[test]" [ fontsize = 8, label = "C2[test]" ] "C3[test]" [ fontsize = 8, label = "C3[test]" ] "C1[test]" [ fontsize = 8, label = "C1[test]" ] "File[/tmp/c2.txt]" [ fontsize = 8, label = "File[/tmp/c2.txt]" ] "File[/tmp/c3.txt]" [ fontsize = 8, label = "File[/tmp/c3.txt]" ] "File[/tmp/c1.txt]" [ fontsize = 8, label = "File[/tmp/c1.txt]" ] "Schedule[puppet]" [ fontsize = 8, label = "Schedule[puppet]" ] "Schedule[hourly]" [ fontsize = 8, label = "Schedule[hourly]" ] "Schedule[daily]" [ fontsize = 8, label = "Schedule[daily]" ] "Schedule[weekly]" [ fontsize = 8, label = "Schedule[weekly]" ] "Schedule[monthly]" [ fontsize = 8, label = "Schedule[monthly]" ] "Schedule[never]" [ fontsize = 8, label = "Schedule[never]" ] "Filebucket[puppet]" [ fontsize = 8, label = "Filebucket[puppet]" ] "C2[test]" -> "C3[test]" [ fontsize = 8 ] } -- 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+unsubscribe@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/76c7823d-aabd-486c-9620-a65c2365fcb4%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.