Re: [Puppet Users] Custom Fact Deployment

2023-08-11 Thread Matthew Dennison
We kind of use both:
Manual facts
* Activate required modules
* Define the group set of facts to be loaded via the automatic facts module

Automatic (using module)
* Define facts by group sets

Manual facts are set when we onboard a server and rarely touched again.
Automatic on the other hand are updated regularly and we average about 500
facts per group set.

Regards
Matt

On Wed, Aug 9, 2023 at 6:27 PM 'aciap...@icloud.com' via Puppet Users <
puppet-users@googlegroups.com> wrote:

> Thank you everyone.
>
> I will try the Martin suggestion, and I will let you know if it’s works
>
>
>
> All the best
>
> Alex
>
>
>
> *From: *puppet-users@googlegroups.com  on
> behalf of Martin Alfke 
> *Date: *Monday, 7 August 2023 at 09:18
> *To: *puppet-users@googlegroups.com 
> *Subject: *Re: [Puppet Users] Custom Fact Deployment
>
> Hi Alessandro,
>
>
>
> There are two options on how to deploy external facts:
>
>
>
> 1. Manual:
>
>
>
> Place the executable bash script in /etc/puppetlabs/facter/facts.d
>
>
>
> 2. Automatic (using a module)
>
>
>
> Add the script (with executable flag) to a module in path facts.d/
>
> Pluginsync will then deploy the bash script to all nodes.
>
>
>
> Please note that pluginsyc will download the bash scripts to any Puppet
> agent, regardless of OS.
>
>
>
> Hth,
>
> Martin
>
>
>
>
>
> On 3. Aug 2023, at 09:32, 'Alessandro Ciappei' via Puppet Users <
> puppet-users@googlegroups.com> wrote:
>
>
>
> Hello All,
>
>
>
> maybe it's already has been discussed, I tried to search but I didn't find
> the right thread.
>
> I'm not expert in Puppet and made simple scripts.
>
>
>
> I'm using RHEL Satellite with Puppet 7 ENC (I know that RHEL want to move
> out from puppet, but until i can integrate it I will use it, after I will
> see).
>
>
>
> I need to crate a custom fact to see some information based on IP Address.
>
> I created a Bash Script that give me an output of the location based on
> CIDR, but I want use full automation and begin to launch specific class
> based on fact.
>
>
>
> I don't know where I need to start, i read how create a fact but it still
> confusing because I can't find the directory where put the script or how
> deploy in all my clients.
>
>
>
> Someone can help me, maybe with step by step to understand it.
>
>
>
> Thank you in advance who want to help me.
>
> All the best
>
> Alex
>
>
>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/e17d49d4-a0e3-4441-86f3-133a227d413cn%40googlegroups.com
> <https://groups.google.com/d/msgid/puppet-users/e17d49d4-a0e3-4441-86f3-133a227d413cn%40googlegroups.com?utm_medium=email_source=footer>
> .
>
>
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Puppet Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/puppet-users/pnDaSW0uOXI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> puppet-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/EBCA31FE-29C8-4563-BCED-311F6CD67F19%40gmail.com
> <https://groups.google.com/d/msgid/puppet-users/EBCA31FE-29C8-4563-BCED-311F6CD67F19%40gmail.com?utm_medium=email_source=footer>
> .
>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/puppet-users/AS8PR03MB674244FABD496447878E5DCCFC12A%40AS8PR03MB6742.eurprd03.prod.outlook.com
> <https://groups.google.com/d/msgid/puppet-users/AS8PR03MB674244FABD496447878E5DCCFC12A%40AS8PR03MB6742.eurprd03.prod.outlook.com?utm_medium=email_source=footer>
> .
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/CAKoz8vtJ3qpjh1Y%2BH7aoqMvkb1mPSP1VjzLZZPvkEMRUSbbfDA%40mail.gmail.com.


Re: [Puppet Users] Custom Fact Deployment

2023-08-09 Thread 'aciap...@icloud.com' via Puppet Users
Thank you everyone.
I will try the Martin suggestion, and I will let you know if it’s works

All the best
Alex

From: puppet-users@googlegroups.com  on behalf 
of Martin Alfke 
Date: Monday, 7 August 2023 at 09:18
To: puppet-users@googlegroups.com 
Subject: Re: [Puppet Users] Custom Fact Deployment
Hi Alessandro,

There are two options on how to deploy external facts:

1. Manual:

Place the executable bash script in /etc/puppetlabs/facter/facts.d

2. Automatic (using a module)

Add the script (with executable flag) to a module in path facts.d/
Pluginsync will then deploy the bash script to all nodes.

Please note that pluginsyc will download the bash scripts to any Puppet agent, 
regardless of OS.

Hth,
Martin



On 3. Aug 2023, at 09:32, 'Alessandro Ciappei' via Puppet Users 
 wrote:

Hello All,

maybe it's already has been discussed, I tried to search but I didn't find the 
right thread.
I'm not expert in Puppet and made simple scripts.

I'm using RHEL Satellite with Puppet 7 ENC (I know that RHEL want to move out 
from puppet, but until i can integrate it I will use it, after I will see).

I need to crate a custom fact to see some information based on IP Address.
I created a Bash Script that give me an output of the location based on CIDR, 
but I want use full automation and begin to launch specific class based on fact.

I don't know where I need to start, i read how create a fact but it still 
confusing because I can't find the directory where put the script or how deploy 
in all my clients.

Someone can help me, maybe with step by step to understand it.

Thank you in advance who want to help me.
All the best
Alex

--
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+unsubscr...@googlegroups.com<mailto:puppet-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/e17d49d4-a0e3-4441-86f3-133a227d413cn%40googlegroups.com<https://groups.google.com/d/msgid/puppet-users/e17d49d4-a0e3-4441-86f3-133a227d413cn%40googlegroups.com?utm_medium=email_source=footer>.

--
You received this message because you are subscribed to a topic in the Google 
Groups "Puppet Users" group.
To unsubscribe from this topic, visit 
https://groups.google.com/d/topic/puppet-users/pnDaSW0uOXI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to 
puppet-users+unsubscr...@googlegroups.com<mailto:puppet-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/EBCA31FE-29C8-4563-BCED-311F6CD67F19%40gmail.com<https://groups.google.com/d/msgid/puppet-users/EBCA31FE-29C8-4563-BCED-311F6CD67F19%40gmail.com?utm_medium=email_source=footer>.

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/AS8PR03MB674244FABD496447878E5DCCFC12A%40AS8PR03MB6742.eurprd03.prod.outlook.com.


Re: [Puppet Users] Custom Fact Deployment

2023-08-07 Thread 'Dirk Heinrichs' via Puppet Users
Am Montag, dem 07.08.2023 um 10:17 +0200 schrieb Martin Alfke:

Please note that pluginsyc will download the bash scripts to any Puppet agent, 
regardless of OS.

..., so if you also have to manage Windows nodes, it's better to write the 
facts in Ruby and put them into "/lib/facter/", with extension 
".rb".

HTH...

Dirk

--

Dirk Heinrichs
Senior Systems Engineer, Delivery Pipeline
OpenText ™ Discovery | Recommind
Phone: +49 2226 15966 18
Email: dhein...@opentext.com
Website: 
www.recommind.de
Recommind GmbH, Von-Liebig-Straße 1, 53359 Rheinbach
Vertretungsberechtigte Geschäftsführer Gordon Davies, Madhu Ranganathan, 
Christian Waida, Registergericht Amtsgericht Bonn, Registernummer HRB 10646
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error) please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is strictly 
forbidden
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. 
Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten 
haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. 
Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail sind nicht 
gestattet.

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/4fd47016ef2f5cee26fa79d268886a51bce81189.camel%40opentext.com.


Re: [Puppet Users] Custom Fact Deployment

2023-08-07 Thread Martin Alfke
Hi Alessandro,

There are two options on how to deploy external facts:

1. Manual:

Place the executable bash script in /etc/puppetlabs/facter/facts.d

2. Automatic (using a module)

Add the script (with executable flag) to a module in path facts.d/
Pluginsync will then deploy the bash script to all nodes.

Please note that pluginsyc will download the bash scripts to any Puppet agent, 
regardless of OS.

Hth,
Martin


> On 3. Aug 2023, at 09:32, 'Alessandro Ciappei' via Puppet Users 
>  wrote:
> 
> Hello All,
> 
> maybe it's already has been discussed, I tried to search but I didn't find 
> the right thread.
> I'm not expert in Puppet and made simple scripts.
> 
> I'm using RHEL Satellite with Puppet 7 ENC (I know that RHEL want to move out 
> from puppet, but until i can integrate it I will use it, after I will see).
> 
> I need to crate a custom fact to see some information based on IP Address.
> I created a Bash Script that give me an output of the location based on CIDR, 
> but I want use full automation and begin to launch specific class based on 
> fact.
> 
> I don't know where I need to start, i read how create a fact but it still 
> confusing because I can't find the directory where put the script or how 
> deploy in all my clients.
> 
> Someone can help me, maybe with step by step to understand it.
> 
> Thank you in advance who want to help me.
> All the best
> Alex
> 
> -- 
> 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+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/puppet-users/e17d49d4-a0e3-4441-86f3-133a227d413cn%40googlegroups.com
>  
> .

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/EBCA31FE-29C8-4563-BCED-311F6CD67F19%40gmail.com.