|
| 1 | +.. _ht-enable-client-reporting: |
| 2 | + |
| 3 | +HOWTO Enable Client Reporting |
| 4 | +============================= |
| 5 | + |
| 6 | +Puppet has the ability to send run status reports back to the server at the |
| 7 | +conclusion of each client run. |
| 8 | + |
| 9 | +SIMP natively supports the `store` (default) and `puppetdb` report storage |
| 10 | +endpoints and can be configured as shown below. |
| 11 | + |
| 12 | +Enable Client Reporting |
| 13 | +----------------------- |
| 14 | + |
| 15 | +Set the following in :term:`Hiera` to enable client reporting: |
| 16 | + |
| 17 | +.. code-block:: yaml |
| 18 | +
|
| 19 | + --- |
| 20 | + pupmod::report: true |
| 21 | +
|
| 22 | +Once puppet applies this setting, clients will start sending reports to the |
| 23 | +server at the conclusion of each puppet run. |
| 24 | + |
| 25 | +Filesystem Reports |
| 26 | +------------------ |
| 27 | + |
| 28 | +By default, the puppet sever will enable the `store` reports target which will |
| 29 | +store the client reports on the local filesystem. |
| 30 | + |
| 31 | +To view the raw reports, you can navigate to the directory output by |
| 32 | +``puppet config print reportdir``. |
| 33 | + |
| 34 | +If the system has been set up for `puppetdb` reports and you need to change it |
| 35 | +back to `store`, set the following in :term:`Hiera`: |
| 36 | + |
| 37 | +.. code-block:: yaml |
| 38 | +
|
| 39 | + --- |
| 40 | + puppetdb::master::config::manage_report_processor: true |
| 41 | + puppetdb::master::config::enable_reports: false |
| 42 | +
|
| 43 | +PuppetDB Reports |
| 44 | +---------------- |
| 45 | + |
| 46 | +If you want to use a :term:`GUI` application like `Puppetboard`_ to connect to |
| 47 | +:program:`puppetdb` for reports, then you will need to ensure that the reports |
| 48 | +are being sent to :program:`puppetdb` by the server. |
| 49 | + |
| 50 | +To do this, set the following in :term:`Hiera`: |
| 51 | + |
| 52 | +.. code-block:: yaml |
| 53 | +
|
| 54 | + --- |
| 55 | + puppetdb::master::config::manage_report_processor: true |
| 56 | + puppetdb::master::config::enable_reports: true |
| 57 | +
|
| 58 | +CLI Reporting |
| 59 | +------------- |
| 60 | + |
| 61 | +You can use the `PuppetDB API`_ to get node reporting using :program:`curl` or |
| 62 | +any other application that connect to a web endpoint and process :term:`JSON` |
| 63 | +output. |
| 64 | + |
| 65 | +SIMP provides a tool called :program:`puppetlast` that can read from both the |
| 66 | +`PuppetDB API`_ as well as the locally stored :term:`YAML` reports for a simple |
| 67 | +view of your environment. |
| 68 | + |
| 69 | +The :program:`puppetlast` command is provided by the :package:`simp-utils` RPM. |
| 70 | + |
| 71 | +.. _Puppetboard: https://github.com/voxpupuli/puppetboard |
| 72 | +.. _PuppetDB API: https://puppet.com/docs/puppetdb/latest/api/index.html |
0 commit comments