Skip to content

Instantly share code, notes, and snippets.

@tbatchelli
Created January 5, 2014 00:55
Show Gist options
  • Save tbatchelli/8262909 to your computer and use it in GitHub Desktop.
Save tbatchelli/8262909 to your computer and use it in GitHub Desktop.
(defplan pull-config
"Plan function to pull the node info into the session, under `:nodetool`"
[]
(let [nv (exec-script ("nodetool" "info"))
node-id (target-id)]
(pallet.actions/assoc-settings
:nodetool
(return-value-expr
[nv]
(let [result (:out nv)]
(assoc (parse-info result) :node-id node-id))))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment