Puppet agent module old version, not using same version as master
Hey people, I am a puppet beginner. We have a puppet module written by somebody else some years ago and I am maintaining it. It also has a custom type defined. Basically the problem is :
- Custom type is written in ruby and has a code error. I've fixed the error and built the module on master.
- The updated module was installed on master (removed old one, installed this one, even upgraded version number).
- Somehow, the puppet agent is still trying to use the older version of module which is installed inside its /var/lib/puppet directory. I cannot change the code as puppet reverts it on next execution.
- Even if I delete the entire /var/lib/puppet/lib directory, it regenerates the code structure which is of the older version.
My questions are :
- Do I need to mention somewhere for the agent to use latest version of module ? Can't master and agent sync for module version ?
- Why is it picking a different (older) version ? Is agent always downloading code from puppet forge ?
Note : I am using Modulefile instead of metadata.json which shows deprecation warning but I hope that is not causing it. Once the issue is fixed, I'll switch to metadata.json too.
Thanks in advance