Scharfenberg, Carsten
2018-10-04 12:43:10 UTC
Hi all,
I have some questions concerning configuring CheckMk via puppet. Some of them more general while others are quite specific.
This one question is dealing with the general approach how to this.
I hope there's somebody out there to share his/her experience with me.
I see several approaches to configure CheckMk via puppet:
1. Taking full control over the files managed by WATO. The result would be that WATO is not usable anymore because all changes get overwritten by puppet. Also I need to replicate all WATO settings with puppet right from the beginning. So this approach seems to be somewhat unfortunate.
2. Having some files configured with WATO, others with puppet. E.g. all hosts and inventory checks would be managed by puppet, whereas additional active checks and users are managed by WATO. This requires that possible sets of changes are disjunct concerning the config files (i.e. I can add active checks using WATO without affecting config files that are managed by puppet). I'm not sure if this is the case.
3. Allowing all files to be configured by WATO and puppet simultaneously. For most software packages this is possible using puppets Augeas feature. Unfortunately CheckMk config files are python source code and I did could find an Augeas lens to deal with python code. I've also tried to use the CheckMK Web-API to achieve this. Again I've encountered the same problem: some web requests use python source code in their body. So I have no solution to implement this approach. I will write a second more detailed question about how to use the CheckMk Web API from puppet/ruby.
4. Having puppet manage its own tree of configuration files (living in etc/check_mk/conf.d/puppet or similar). I haven't tried out this approach. I'm completely unsure how puppet and WATO settings will interact with each other in this case. Would it be possible to add a host via puppet and then add a service to this host via WATO? (There are a lot more questions like this).
I would be happy if someone who has experience with one or the other approach contacted me.
Also, maybe there are approaches that I haven't thought about.
Thanks and Best regards,
Carsten
I have some questions concerning configuring CheckMk via puppet. Some of them more general while others are quite specific.
This one question is dealing with the general approach how to this.
I hope there's somebody out there to share his/her experience with me.
I see several approaches to configure CheckMk via puppet:
1. Taking full control over the files managed by WATO. The result would be that WATO is not usable anymore because all changes get overwritten by puppet. Also I need to replicate all WATO settings with puppet right from the beginning. So this approach seems to be somewhat unfortunate.
2. Having some files configured with WATO, others with puppet. E.g. all hosts and inventory checks would be managed by puppet, whereas additional active checks and users are managed by WATO. This requires that possible sets of changes are disjunct concerning the config files (i.e. I can add active checks using WATO without affecting config files that are managed by puppet). I'm not sure if this is the case.
3. Allowing all files to be configured by WATO and puppet simultaneously. For most software packages this is possible using puppets Augeas feature. Unfortunately CheckMk config files are python source code and I did could find an Augeas lens to deal with python code. I've also tried to use the CheckMK Web-API to achieve this. Again I've encountered the same problem: some web requests use python source code in their body. So I have no solution to implement this approach. I will write a second more detailed question about how to use the CheckMk Web API from puppet/ruby.
4. Having puppet manage its own tree of configuration files (living in etc/check_mk/conf.d/puppet or similar). I haven't tried out this approach. I'm completely unsure how puppet and WATO settings will interact with each other in this case. Would it be possible to add a host via puppet and then add a service to this host via WATO? (There are a lot more questions like this).
I would be happy if someone who has experience with one or the other approach contacted me.
Also, maybe there are approaches that I haven't thought about.
Thanks and Best regards,
Carsten