CUT-5060: Password Manager Install for Managed Users Only#728
Open
CUT-5060: Password Manager Install for Managed Users Only#728
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issues
What does this solve?
This pull request addresses the requested changes to only install the JumpCloud Password Manager for JumpCloud managed users. Previously the application would be installed if the user was managed or not.
Is there anything particularly tricky?
The Mac command has the biggest changes. The previous behavior was that it would install the JumpCloud Password Manager on all user accounts while the Windows command would only install on the current user. We also have to account for Mac device that do not have jq installed and revert to standard Bash to query the .json file.
I made some minor changes to the Windows command using
Write-Outputinstead ofWrite-Errorbecause it would a clog up the Command log by pasting the entire script to report the error; withWrite-Outputonly the 'error' is returned.How should this be tested?
Mac Testing
Windows Testing
Note
Medium Risk
Medium risk because it changes install/update targeting logic based on
managedUsers.json, which could prevent installs/updates if the managed-users file is missing, unreadable, or parsed incorrectly.Overview
Password Manager install/update now targets managed users only.
On macOS, the command loads usernames from
/opt/jc/managedUsers.json(usingjqwhen available with a grep/sed fallback) and skips all local accounts not in that list for both version checks and app copy/install; it also exits early when no managed home directories are present on forced reinstall.On Windows, the command now reads
$env:ProgramFiles\JumpCloud\Plugins\Contrib\managedUsers.jsonand exits if the currently logged-in user is not managed, and it switches some failure paths fromWrite-ErrortoWrite-Outputto reduce noisy command logs. Command gallery entries were version-bumped (Mac v2.0.2,Windows v2.0.1) and updated incommands.json.Written by Cursor Bugbot for commit 9580a7d. This will update automatically on new commits. Configure here.