Commit 1420c492 by Michael DeHaan

Still seeing some weirdness from ohai but we can probably simplify

this until we figure out what that is.
parent e6a1acf7
#!/usr/bin/python
#!/bin/bash
# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>
#
......@@ -18,17 +18,4 @@
# along with Ansible. If not, see <http://www.gnu.org/licenses/>.
#
# requires 'ohai' to be installed
try:
import json
except ImportError:
import simplejson as json
import subprocess
cmd = subprocess.Popen("/usr/bin/ohai", stdout=subprocess.PIPE, stderr=subprocess.PIPE)
out, err = cmd.communicate()
# try to cleanup the JSON, for some reason facter --json doesn't need this hack
print json.dumps(json.loads(out))
/usr/bin/ohai
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment