Skip to content

Instantly share code, notes, and snippets.

@lloesche
Created May 16, 2018 16:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lloesche/070932483faee3c2850cd23433b977a0 to your computer and use it in GitHub Desktop.
Save lloesche/070932483faee3c2850cd23433b977a0 to your computer and use it in GitHub Desktop.
dump DC/OS pre-cockroachdb IAM data
#!/usr/bin/env python3
import logging
logging.basicConfig()
from kazoo.client import KazooClient
zk = KazooClient(hosts='10.0.28.160:2181', auth_data=[("digest", "super:xxxxxxxxxx")])
zk.start()
data, stat = zk.get("/bouncer/datastore/data.json")
text_file = open("data.json", "w")
text_file.write(data.decode("utf-8"))
text_file.close()
zk.stop()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment