Posted on 04-22-2019 10:07 AM
I'm trying to assign default homepage using HomepageLocation in com.google.Chrome.plist
It doesn't seem to be doing anything. I don't see the key when I do defaults read com.google.Chrome
Is it more complicated than this?
Posted on 04-22-2019 10:15 AM
copied from this thread - https://www.jamf.com/jamf-nation/discussions/31397/setting-default-applications - this walks you through how to set chrome as the default browser & the plist at the bottom for default pages upon load
I believe by adding these lines to the users com.apple.launchservices.secure.plist (Located -> '/Users/$USERNAME/Library/Preferences/com.apple.LaunchServices/com.apple.launchservices.secure.plist ')
<key>LSHandlerRoleAll</key>
<string>-</string>
</dict>
<key>LSHandlerRoleAll</key>
<string>com.google.Chrome</string>
<key>LSHandlerURLScheme</key>
<string>http</string>
</dict>
<dict>
<key>LSHandlerPreferredVersions</key>
<dict>
<key>LSHandlerRoleAll</key>
<string>-</string>
</dict>
<key>LSHandlerRoleAll</key>
<string>com.google.Chrome</string>
<key>LSHandlerURLScheme</key>
<string>https</string>
</dict>
<dict>
<key>LSHandlerPreferredVersions</key>
<dict>
<key>LSHandlerRoleAll</key>
<string>-</string>
</dict>
<key>LSHandlerRoleAll</key>
<string>com.google.Chrome</string>
<key>LSHandlerURLScheme</key>
<string>ftp</string>
</dict>
<dict>
<key>LSHandlerContentType</key>
<string>public.html</string>
<key>LSHandlerPreferredVersions</key>
<dict>
<key>LSHandlerRoleAll</key>
<string>-</string>
</dict>
<key>LSHandlerRoleAll</key>
<string>com.google.Chrome</string>
</dict>
& then deploying a plist (i did it with a config profile -> "Custom Settings" with the plist passed as is displayed in secure plist above ie "com.google.Chrome" - you want to save the plist as "com.google.chrome.plist" before uploading it.
Image Example Below - "Upload_Field_Custom_Settings_Filename" is where you upload the plist.
You can upload the following plist & config it how you see fit,
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>DefaultBrowserSettingEnabled</key>
<false/>
<key>HomepageIsNewTabPage</key>
<false/>
<key>HomepageLocation</key>
<string>www.Website Homepage.com</string>
<key>RestoreOnStartupURLs</key>
<array>
<string>www.Website 1.com</string>
<string>www.Website 2.com</string>
<string>www.Website 3.com</string>
</array>
<key>RestoreOnStartup</key>
<integer>4</integer>
<key>ShowHomeButton</key>
<true/>
<key>IncognitoModeAvailability</key>
<integer>1</integer>
</dict>
</plist>
Posted on 04-22-2019 10:32 AM
Yeah, that's what I did. The second part. I have com.google.Chrome.plist . I uploaded it as a configuration profile. It's being applied but when I do `/usr/bin/defaults read com.google.Chrome' it doesn't show it is applied.
Posted on 04-22-2019 11:43 AM
@dswitmer How about this?
defaults read ~/Library/Preferences/com.google.Chrome
Posted on 04-23-2019 06:46 AM
Yeah, neither. If I do the preference with custom Plist and chrome isn't even installed yet, I should still be able to read com.google.Chrome right? I mean it should be writing it even if Chrome isn't installed yet, right?
Posted on 04-23-2019 07:52 AM
If you create a profile in ProfileCreator does it work for you?
Posted on 08-11-2021 05:47 PM
Can you explain HOW TO DO this? Installed profile creator, no chrome options by default. Where do they come from?
Posted on 04-23-2019 08:45 AM
Hello @sshort I have also had issues with setting a Chrome homepage. When I tried using ProfileCreator, I haven't been able to get this to load any payload for Chrome. I configured the homepage as you did above. I then exported the profile to my desktop and imported it into my configuration profiles. There is only a description and no payload. I must be doing something wrong...thoughts?
I exported as a profile. Should I be exporting as MCX?
Posted on 04-23-2019 09:09 AM
Open Chrome, check for installed policies in the address bar:
chrome://policy
If your homepage policy does not show then it’s not being applied correctly.
Do you have another Chrome config profile which is overlapping this one?