Specific answer: Immediately speaking, you're calling sysctl::value, but value isn't declared in your sysctl class. See this example that uses a sysctl::conf declaration. Without the define value
, there is no sysctl::value subclass for you to call.
General answer and guidance: The Augeas construct (see also its type reference documentation) that is part of current versions of Puppet allows maintaining lines in a configuration file and even respects context, so it can manage files such as a git configuration. The example below is both to demonstrate functionality and to point you to a great reference collection of Puppet configs -- the live configuration store for Wikipedia servers.
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = https://gerrit.wikimedia.org/r/p/operations/puppet
[branch "production"]
remote = origin
merge = refs/heads/production
One simple example from the above configuration documentation would be this:
augeas { "sshd_config":
context => "/files/etc/ssh/sshd_config",
changes => [
"set PermitRootLogin no",
],
}
So, if you want to manage your /etc/sysctl.conf, enter the following:
augeas { "sysctl":
context => "/files/etc/sysctl.conf",
changes => [
"set kernel.sysrq = 0",
#and whatever other lines are interesting to you
],
}
The Augeas example also has a construct for a sysctl class based on Augeus that is similar to what you posted in your question, so that may also shed some light.
I think I finally tracked down a couple Puppet bugs which appear to be the cause of this. It is related to my use of multiple environments for testing and updating (which I didn't mention in the original problem since I didn't think it was relevant).
The first bug which showed up in a Google search after removing 'identifier' from my search term:
http://projects.puppetlabs.com/issues/17814
Then, this bug links to another which sounds like it is directly related:
http://projects.puppetlabs.com/issues/12173
I am also following http://projects.puppetlabs.com/issues/17210 and it could be related. I am following these bugs. I can confirm that after I actually merged my code to the main environment, it did start working (since the Puppet master now saw the code changes).
Best Answer
You still have to download that module from the forge first:
It will put it in the default modulepath, but you can override that with the --modulepath switch.
You can see the mentioned command at the URL that you mentioned... ;)
You then 'use' that module like this: