This check monitors OctoPrint through the Datadog Agent.
Setup
Follow the instructions below to install and configure this check for an Agent running on a host. For containerized environments, see the Autodiscovery Integration Templates for guidance on applying these instructions.
Installation
To install the OctoPrint check on your host by running:
Upload the build artifact to any host with an Agent and
run datadog-agent integration install -w path/to/octoprint/dist/datadog_octoprint*.whl.
Configuration
From the OctoPrint web interface, create an API key for use with Datadog. This can be found within Settings –> Application Keys.
Edit the octoprint.d/conf.yaml file, in the conf.d/ folder at the root of your Agent’s configuration directory. Paste the OctoPrint API key as the value for octo_api_key. See the sample octoprint.d/conf.yaml for all available configuration options.
By default this integration assumes that you are using the OctoPi image that is pre-configured to run OctoPrint from a Raspberry Pi.
The logs that it collects by default (and their default locations) are:
OctoPrint App log: /home/pi/.octoprint/logs
OctoPrint Webcam log: /var/log/webcamd.log
HA Proxy log: /var/log/haproxy.log
Any or all of these may be changed or removed by modifying the integration’s conf.yaml file.
Log processing
OctoPrint uses its own log format (not an object format). To make use of the logs, create a log processing pipeline with some parsing rules, for example: