summaryrefslogtreecommitdiffstats
path: root/yaml1.py
diff options
context:
space:
mode:
Diffstat (limited to 'yaml1.py')
-rw-r--r--yaml1.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/yaml1.py b/yaml1.py
new file mode 100644
index 0000000..30feff3
--- /dev/null
+++ b/yaml1.py
@@ -0,0 +1,11 @@
+import yaml
+import pprint as pp
+
+with open('config.yaml', "r") as f:
+ yamlconfig = yaml.load(f, Loader=yaml.FullLoader)
+
+#pp.pprint(yamlconfig)
+#for i, d in yamlconfig.items():
+# print(i, ":", d)
+
+print(yamlconfig['server']['users'][0]['ssh_key'])