Hi Isuru,
Yes, that is what I understand from the docs so far. However it seems
Puppet looks for a folder in the ruby lib path named facter. The
puppetinstall script copies the stratos_sendinfo.rb file to ruby lib root,
and not to a facter folder within it.
puppetinstall:247
if [ -d /usr/lib/ruby/1.8 ]; then
cp /root/bin/stratos_sendinfo.rb /usr/lib/ruby/1.8
fi
And in the php module there is a custom facter script in the right folder
but as I've read [1] a setting must be enabled both on the server and the
client side to enable automatic plugin sync.
I'm in the process of converting these puppet modules to chef, and some of
these details keep hidden so far.
[1] -
https://docs.puppetlabs.com/guides/plugins_in_modules.html#enabling-pluginsync
Regards,
Chamila de Alwis
Software Engineer | WSO2 | +94772207163
Blog: code.chamiladealwis.com
On Thu, Aug 21, 2014 at 7:52 AM, Isuru Haththotuwa <[email protected]>
wrote:
> Hi Chamila,
>
> Not aware of the internals very much, but all the facter scripts get
> executed at instance startup and facters will be available in the Puppet
> Master side [1]. I'm not sure how and when these are getting loaded, though.
>
> [1]. https://docs.puppetlabs.com/facter/2.0/custom_facts.html
>
> On Thu, Aug 21, 2014 at 4:09 AM, Chamila De Alwis <[email protected]>
> wrote:
>
>> Hi,
>>
>> The file tools/puppet3-agent/stratos_sendinfo.rb contains the logic on
>> adding user-data from the payload as facts to the system. The install
>> script, puppetinstall, copies this file to /usr/lib/ruby/1.8/, however I
>> couldn't find the place where it is being loaded.
>>
>> Furthermore are the custom facts included with php automatically run when
>> puppet runs? Puppet will add facts included in the lib/facter folder, but
>> doesn't it need pluginsync setting to enabled in the puppet.conf?
>>
>
>
>> Regards,
>> Chamila de Alwis
>> Software Engineer | WSO2 | +94772207163
>> Blog: code.chamiladealwis.com
>>
>> --
>> <http://code.chamiladealwis.com>
>> Thanks and Regards,
>>
>> Isuru H.
>> <http://code.chamiladealwis.com>
>> +94 716 358 048 <http://code.chamiladealwis.com>* <http://wso2.com/>*
>>
>>
>> * <http://wso2.com/>*
>>
>>
>>