View difference between Paste ID: wYAPsHWn and kaYRyAiM
SHOW: | | - or go back to the newest paste.
1
manifests/nodes.pp
2
##################################
3
node testnode.domain {
4
    include test_module
5
}
6
##################################
7
8
9
modules/test_module/init.pp
10
##################################
11
class test_module ($test = "basetest") {
12
13
	notify {"${test}":;}
14
        class { "test_module::test_implementation::test": subtest => "imp_subtest" }
15
}
16
##################################
17
18
19
modules/test_module/test_implementation/test.pp
20
##################################
21
class test_module::test_implementation::test ($subtest = "subtest") {
22
    notify {"${subtest}":; }
23
    notify {"Unqualified ${test}":;}
24
    notify {"FQ ${Test_module::test}":;}
25
}
26
####################################################
27
28
Syslog output from puppetmaster:
29
####################################################
30
Mar  7 02:08:50 testmaster puppet-master[6082]: (Scope(Class[Test_module])) Could not look up qualified variable 'data::testnode.domain::test_module::test'; class data::testnode.domain::test_module could not be found
31
Mar  7 02:08:50 testmaster puppet-master[6082]: Compiled catalog for testnode.domain in environment woofie in 0.24 seconds
32
####################################################
33
34
Agent Output on testnode.domain:
35
####################################################
36
root@testnode:~# puppet agent -t --environment=testenv
37
Info: Retrieving plugin
38-
Info: Loading facts in /var/lib/puppet/lib/facter/puppet_vardir.rb
38+
Info: Loading facts in /var/lib/puppet/lib/facter/inventory.rb
39-
Info: Loading facts in /var/lib/puppet/lib/facter/broadcast_eth0.rb
39+
40-
Info: Loading facts in /var/lib/puppet/lib/facter/pe_version.rb
40+
41-
Info: Loading facts in /var/lib/puppet/lib/facter/root_home.rb
41+
42-
Info: Loading facts in /var/lib/puppet/lib/facter/iptables.rb
42+
43-
Info: Loading facts in /var/lib/puppet/lib/facter/default_route.rb
43+
44-
Info: Loading facts in /var/lib/puppet/lib/facter/facter_dot_d.rb
44+
45
Notice: FQ basetest
46
Notice: /Stage[main]/Test_module::Test_implementation::Test/Notify[FQ basetest]/message: defined 'message' as 'FQ basetest'
47
Notice: imp_subtest
48
Notice: /Stage[main]/Test_module::Test_implementation::Test/Notify[imp_subtest]/message: defined 'message' as 'imp_subtest'
49
Notice: Finished catalog run in 0.11 seconds