From 1abc0153f58c1d939f23a49b9508749872310be1 Mon Sep 17 00:00:00 2001 From: Franziska Kunsmann Date: Thu, 18 Feb 2021 15:12:30 +0100 Subject: [PATCH] bundles/openssh: do not add deleted users to ssh config --- bundles/openssh/items.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/openssh/items.py b/bundles/openssh/items.py index 4760d87..4636b1b 100644 --- a/bundles/openssh/items.py +++ b/bundles/openssh/items.py @@ -2,7 +2,7 @@ users_from_metadata = set() additional_users = node.metadata.get('openssh', {}).get('allowed_users', set()) for user, config in node.metadata.get('users', {}).items(): - if 'ssh_pubkey' in config: + if 'ssh_pubkey' in config and not config.get('delete', False): users_from_metadata.add(user) login_users = users_from_metadata.union(additional_users)