{"id":1726,"date":"2010-08-20T21:55:44","date_gmt":"2010-08-20T20:55:44","guid":{"rendered":"http:\/\/www.devco.net\/?p=1726"},"modified":"2010-08-20T21:55:44","modified_gmt":"2010-08-20T20:55:44","slug":"marionette_collective_version_048","status":"publish","type":"post","link":"https:\/\/www.devco.net\/archives\/2010\/08\/20\/marionette_collective_version_048.php","title":{"rendered":"Marionette Collective version 0.4.8"},"content":{"rendered":"

I just released version 0.4.8 of mcollective<\/a>. It’s a small maintenance release fixing a few bugs and adding a few features. I wasn’t planning on another 0.4.x release before the big 1.0.0 but want to keep 1.0.0 close as possible to something that’s been out there for a while.<\/p>\n

The only major feature it introduces is custom reports<\/a> of your infrastructure.<\/p>\n

It supports two types of scriptlet for building reports. The first is a little DSL that uses printf<\/em> style format strings:<\/p>\n

<\/p>\n

\r\ninventory do\r\n    format \"%s:\\t\\t%s\\t\\t%s\"\r\n \r\n    fields { [ identity, facts[\"serialnumber\"], facts[\"productname\"] ] }\r\nend\r\n<\/pre>\n

<\/code><\/p>\n

Which does something like this:<\/p>\n

<\/p>\n

\r\n$ mc-inventory --script hardware.mc\r\nweb1:           KKxxx1H         IBM eServer BladeCenter HS20 -[8832M1X]-\r\nrep1:           KKxxx5Z         IBM eServer BladeCenter HS20 -[8832M1X]-\r\ndb4:            KDxxxZY         IBM System x3655 -[794334G]-\r\nman2:           KDxxxR0         eserver xSeries 336 -[88372CY]-\r\ndb2:            KDxxxGD         IBM System x3655 -[79855AG]-\r\n<\/pre>\n

<\/code><\/p>\n

The other – perhaps more ugly – is using a Perl like format method. To use this you need the formatr<\/em> gem installed, and a report might look like this:<\/p>\n

<\/p>\n

\r\nformatted_inventory do\r\n    page_length 20\r\n\r\n    page_heading <\n

<\/code><\/p>\n

And the resulting report is something like this:<\/p>\n

<\/p>\n

\r\n$ mc-inventory --script hardware.mc\r\n            Node Report Fri Aug 20 21:49:39 +0100\r\n\r\nHostname:         Customer:     Distribution:\r\n-------------------------------------------------------------------------\r\n\r\nweb1              rip           CentOS release 5.5 (Final)\r\n                                Intel(R) Xeon(R) CPU           L5420  \r\n\r\nweb2              xxxxxxx       CentOS release 5.5 (Final)\r\n                                Intel(R) Xeon(R) CPU           X3430  \r\n<\/pre>\n

<\/code><\/p>\n

The report will be paged 20 nodes per page. The result is very pleasing even if the report format is a bit grim, but it would be much worse to write yet another reporting DSL!<\/p>\n

See the full release notes<\/a> for details on bug fixes and other features.<\/p>\n","protected":false},"excerpt":{"rendered":"

I just released version 0.4.8 of mcollective. It’s a small maintenance release fixing a few bugs and adding a few features. I wasn’t planning on another 0.4.x release before the big 1.0.0 but want to keep 1.0.0 close as possible to something that’s been out there for a while. The only major feature it introduces […]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_et_pb_use_builder":"","_et_pb_old_content":"","footnotes":""},"categories":[1],"tags":[85,78],"_links":{"self":[{"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/posts\/1726"}],"collection":[{"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/comments?post=1726"}],"version-history":[{"count":5,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/posts\/1726\/revisions"}],"predecessor-version":[{"id":1731,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/posts\/1726\/revisions\/1731"}],"wp:attachment":[{"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/media?parent=1726"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/categories?post=1726"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devco.net\/wp-json\/wp\/v2\/tags?post=1726"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}