{"id":18811716,"url":"https://github.com/logicmonitor/logicmonitor-puppet-v4","last_synced_at":"2025-07-16T21:02:43.122Z","repository":{"id":11115598,"uuid":"62672066","full_name":"logicmonitor/logicmonitor-puppet-v4","owner":"logicmonitor","description":"LogicMonitor Puppet Module","archived":false,"fork":false,"pushed_at":"2022-06-01T18:11:50.000Z","size":129,"stargazers_count":6,"open_issues_count":4,"forks_count":7,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-03-27T11:21:32.453Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/logicmonitor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-07-05T21:51:19.000Z","updated_at":"2022-04-27T16:46:03.000Z","dependencies_parsed_at":"2022-09-10T09:10:11.269Z","dependency_job_id":null,"html_url":"https://github.com/logicmonitor/logicmonitor-puppet-v4","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logicmonitor%2Flogicmonitor-puppet-v4","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logicmonitor%2Flogicmonitor-puppet-v4/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logicmonitor%2Flogicmonitor-puppet-v4/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logicmonitor%2Flogicmonitor-puppet-v4/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/logicmonitor","download_url":"https://codeload.github.com/logicmonitor/logicmonitor-puppet-v4/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248336805,"owners_count":21086880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T23:27:24.861Z","updated_at":"2025-04-13T20:31:31.639Z","avatar_url":"https://github.com/logicmonitor.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"#LogicMonitor-Puppet-v4\n\nLogicMonitor is a Cloud-based, full stack, IT infrastructure monitoring solution that\nallows you to manage your infrastructure monitoring from the Cloud.\nLogicMonitor-Puppet-v4 is a Puppet module for automating and managing your LogicMonitor\n(SaaS based, full stack, datacenter monitoring) portal via Puppet, specifically for version 4.\n\n##LogicMonitor's Puppet module overview\nLogicMonitor's Puppet module defines 5 classes and 4 custom resource types. For additional documentation visit \n\u003cinsert Help Documentation URL\u003e\n\nClasses:\n* logicmonitor: Handles setting credentials needed for interacting with the LogicMonitor API.\n* logicmonitor::master: Collects the exported lm_host resources and lm_hostgroup resources. Communicates with the LogicMonitor API\n* logicmonitor::collector: Handles LogicMonitor collector management for the device. Declares an instance of lm_collector and lm_installer resources.\n* logicmonitor::device: Declares an exported lm_device resource.\n* logicmonitor::device_group: Declares an export lm_device_group resource. \n\nResource Types:\n* lm_device_group: Defines the behavior of the handling of LogicMonitor device groups. Recommend using exported resources.\n* lm_device: Defines the handling behavior of LogicMonitor devices. Used only within logicmonitor::device class.\n* lm_collector: Defines the handling behavior of LogicMonitor collectors. Used only with logicmonitor::collector class.\n* lm_installer: Defines the handling behavior of LogicMonitor collector installation binaries. Used only within logicmonitor::collector class.\n\nSo far, we've implemented the following features:\n\n* Collector Management\n* Device Management\n  * Ensurable (present/absent)\n  * Managed parameters:\n    * Display name\n    * Description\n    * Collector\n    * Disable Alerting\n    * Group membership\n      * Creation of groups/paths which do not yet exist\n    * Properties\n* Device Group Management\n  * Ensurable (present/absent)\n  * Managed parameters:\n    * Display name\n    * Description\n    * Collector\n    * Disable Alerting\n    * Creation of parent groups/paths which do not yet exist\n    * Properties\n\nUpcoming features:\n\n* User management\n  * Add and remove users\n  * Assign user roles\n\n## Requirements\n\n** Ruby (1.9.3, 2.0.X, 2.1.X) and Puppet 3.X OR 4.X **\n\nThis is a module written for Puppet 4\n\n** Ruby Gems  JSON Gem **\n\nThis module interacts with LogicMonitor's API which is JSON based. \nThe JSON gem needed to parse responses from the LogicMonitor API. \nOur Gemfile enforces json ruby gem version 1.7.7, which may be installed \nvia\n```\n$ bundle install\n```\n\n** storeconfigs **\n\nThis module uses exported resources extensively. Exported resources require storeconfigs = true.\n\n## Installation\n\n### Using the Module Tool\n\n    $ puppet module install logicmonitor-logicmonitor\n\n### Installing via GitHub\n\n    $ cd /etc/puppet/modules\n    $ git clone git://github.com/logicmonitor/logicmonitor-puppet-v4.git\n    $ mv logicmonitor-puppet-v4 logicmonitor\n\n## Usage\n\nAdd a LogicMonitor class with your LogicMonitor account information\n\n    class { 'logicmonitor':\n            account    =\u003e 'puppettest',\n            access_id  =\u003e 'XXX',\n            access_key =\u003e 'XXX',\n    }\n\n### Logicmonitor::Master Node\n\nThe LogicMonitor module uses the the \"logicmonitor::master\" class as trigger\nto decide which device in your infrastructure will be used to modify your\nLogicMonitor account via API calls.  This device must be able to communicate via\nSSL with your LogicMonitor account.\n\n\n    node \"puppet-master.lax6.chimpco\" {\n      # the puppet master is where API calls to the LogicMonitor server are sent from\n      include logicmonitor::master\n\n      # In this example, the master will also have a collector installed.  This is optional - the\n      # collector can be installed anywhere.\n      # NOTE:  this collector will be identied by the facter derived FQDN, eg\n      # \"puppet-master.lax6.chimpco\" in this case.\n      include logicmonitor::collector\n\n      # Define default properties and some device groups\n      #\n      # Managing the properties on the root device group (\"/\") will set the properties for the entire\n      # LogicMonitor account.  These properties can be over-written by setting them on a child\n      # group, or on an individual device.\n      #\n      # There are 2 methods for defining device groups.\n      # If you are only defining a single device group resource per node definition,\n      # You can use the class syntax.\n      # \n      # e.g.\n      #\n      # class { 'logicmonitor::device_group' :\n      #   full_path  =\u003e \"/\",\n      #   properties =\u003e {\n      #     \"snmp.community\"  =\u003e \"public\",\n      #     \"tomcat.jmxports\" =\u003e \"9000\",\n      #     \"mysql.user\"      =\u003e \"monitoring\",\n      #     \"mysql.pass\"      =\u003e \"MyMysqlPW\"\n      #   },\n      # }\n      #\n      # Otherwise, you will need to define device groups using the device_group resource\n      # notation.\n      #\n      # We recommend defining device groups as exported resources.\n      #\n\n      # create \"Development\" and \"Operations\" device groups\n      @@device_group { \"/Development\":\n        full_path  =\u003e ,\n        description =\u003e 'This is the top level puppet managed device group',\n      }\n\n      @@device_group {\"/Operations\":}\n      \n      # Create US-West device group, as well as a sub-group \"production\".\n      # The \"production\" group will have use a different SNMP community\n\n      @@device_group{\"/US-West\":}\n\n      @@device_group{\"/US-West/production\":\n        properties =\u003e { \"snmp.community\"=\u003e\"secret_community_RO\" },\n      }\n      \n      @@device_group{\"/US-East\":}\n\n\n      # Your puppet master node should be monitored too of course!  Add it in,\n      # place it in two device groups, and set device specific custom properties\n      # that you might use for a custom datasource\n      class {'logicmonitor::device':\n        collector =\u003e \"puppet-master.lax6.chimpco\",\n        groups =\u003e [\"/Operations\", \"/US-West\"],\n        properties =\u003e {\"test.prop\" =\u003e \"test2\", \"test.port\" =\u003e 12345 },\n      }\n    }\n\n### Add all appX.lax6 nodes into monitoring\n\n    node /^app\\d+.lax6/ {\n      $lm_collector = \"puppet-master.lax6.chimpco\"\n\n      class {'logicmonitor::device':\n        collector =\u003e $lm_collector,\n        groups =\u003e [\"/US-West/production\"],\n        properties =\u003e {\"jmx.pass\" =\u003e \"MonitorMEEEE_pw_\", \"jmx.port\" =\u003e 12345 },\n      }\n    }\n\n### Additional collector and East Coast nodes\n\n    # Install a collector on a dedicated machine for monitoring the East Coast\n    # data center\n    node \"collector1.dc7.chimpco\" {\n\n      # install a collector on this machine.  It is identified\n      # by the facter derived fqdn\n      include logicmonitor::collector\n\n      # and add it into monitoring\n      class {'logicmonitor::device':\n        collector  =\u003e \"collector1.dc7.chimpco\",\n        groups     =\u003e [\"/US-East\",\"Operations\"]\n      }\n    }\n\n    # All East coast nodes will be monitored by the previously defined collector\n    node /^app\\d+.dc7/ {\n      class {\"logicmonitor::device\":\n        collector =\u003e \"collector1.dc7.chimpco\",\n        groups =\u003e [\"/US-East\"],\n      }\n    }\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogicmonitor%2Flogicmonitor-puppet-v4","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flogicmonitor%2Flogicmonitor-puppet-v4","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogicmonitor%2Flogicmonitor-puppet-v4/lists"}