Last active
September 30, 2018 03:29
-
-
Save nstrauss/f891f74c05e26539dece88c42fba0124 to your computer and use it in GitHub Desktop.
NoMAD Login AD postinstall example
This file contains 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
#!/bin/bash | |
# Preference key reference | |
# https://gitlab.com/orchardandgrove-oss/NoMADLogin-AD/wikis/Configuration/preferences | |
domain="domain.com" | |
background_image="/path/to/image.png" | |
logo="/path/to/logo.png" | |
# Set default AD domain | |
defaults write /Library/Preferences/menu.nomad.login.ad.plist ADDomain "$domain" | |
# Set background image | |
defaults write /Library/Preferences/menu.nomad.login.ad.plist BackgroundImage "$background_image" | |
# Set login window logo | |
defaults write /Library/Preferences/menu.nomad.login.ad.plist LoginLogo "$logo" | |
# Set security authorization database mechanisms with authchanger | |
/usr/local/bin/authchanger -reset -AD | |
# Kill loginwindow process to force NoMAD Login to launch | |
/usr/bin/killall -HUP loginwindow | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment