From 11d2d70fd8a0d4b79da6fc6b0f2c792a4497085d Mon Sep 17 00:00:00 2001 From: Alex Willmer Date: Fri, 7 Feb 2025 00:16:57 +0000 Subject: [PATCH] CI: Use native Ansible support to hide macOS users --- tests/image_prep/_user_accounts.yml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/tests/image_prep/_user_accounts.yml b/tests/image_prep/_user_accounts.yml index bb8067f9..c47b1dce 100644 --- a/tests/image_prep/_user_accounts.yml +++ b/tests/image_prep/_user_accounts.yml @@ -86,20 +86,11 @@ ['com.apple.access_ssh'] + (user_groups[item.name] | default(['mitogen__group'])) }} + hidden: true password: "{{ password }}" with_items: "{{all_users}}" when: ansible_system == 'Darwin' - - name: Hide users from login window (Darwin). - when: ansible_system == 'Darwin' - with_items: "{{all_users}}" - osx_defaults: - array_add: true - domain: /Library/Preferences/com.apple.loginwindow - type: array - key: HiddenUsersList - value: ['{{ item.name }}'] - - name: Check if AccountsService is used stat: path: /var/lib/AccountsService/users