summaryrefslogtreecommitdiff
path: root/tools/sops-inventory
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2023-01-30 14:30:12 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2023-01-30 14:30:12 +0100
commit1a69390d630e4f886e46ab2d9817d2b352f05aa9 (patch)
tree53346d5464b74dbbca39e759463678825df819cb /tools/sops-inventory
parentce00897302018b614f22344822cea36bc36ff06f (diff)
downloadnixos-1a69390d630e4f886e46ab2d9817d2b352f05aa9.tar
nixos-1a69390d630e4f886e46ab2d9817d2b352f05aa9.tar.gz
nixos-1a69390d630e4f886e46ab2d9817d2b352f05aa9.tar.bz2
nixos-1a69390d630e4f886e46ab2d9817d2b352f05aa9.tar.xz
nixos-1a69390d630e4f886e46ab2d9817d2b352f05aa9.zip
...
Diffstat (limited to 'tools/sops-inventory')
-rw-r--r--tools/sops-inventory/sops_inventory/__main__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/sops-inventory/sops_inventory/__main__.py b/tools/sops-inventory/sops_inventory/__main__.py
index 3f694917..f84567d3 100644
--- a/tools/sops-inventory/sops_inventory/__main__.py
+++ b/tools/sops-inventory/sops_inventory/__main__.py
@@ -53,7 +53,7 @@ def sops_files(path):
53 files = sorted(map(lambda child: path / child.decode('utf-8').strip(), readnull(proc.stdout)), key=attrgetter('parts')) 53 files = sorted(map(lambda child: path / child.decode('utf-8').strip(), readnull(proc.stdout)), key=attrgetter('parts'))
54 for child in files: 54 for child in files:
55 try: 55 try:
56 with child.open(mode='r') as fh: 56 with child.open(mode='rb') as fh:
57 yaml = load(fh, Loader=Loader) 57 yaml = load(fh, Loader=Loader)
58 if not yaml: 58 if not yaml:
59 raise ValueError('Could not parse YAML') 59 raise ValueError('Could not parse YAML')