Setting default user items

Not applicable

I have a task that appears to be answered by Composer (or it should be) where I need to set the default web browser and home page for the end users at our location. I configure my local admin account as I want it then launch Composer. There is a tab for user environment elements and I click on that. I select the internet config option which should have the settings I'm trying to influence and the package is created without error.

Now I send the package to a test computer and launch a web browser to check the settings. Nothing has been transferred. How do I edit elements of a user's web settings without wiping out everything? I have considered using an Applescript or other type of script but the library for changing those items are slim. Any help would be great.

12 REPLIES 12

milesleacy
Valued Contributor

You can edit the HomePage key in
~/Library/Preferences/com.apple.Safari.plist using defaults or PlistBuddy.
You can also use Open Directory (via Workgroup Manager) or dscl to set this
preference via MCX.

----------
Miles A. Leacy IV

? Certified System Administrator 10.4
? Certified Technical Coordinator 10.5
? Certified Trainer
Certified Casper Administrator
----------
voice: 1-347-277-7321
miles.leacy at themacadmin.com
www.themacadmin.com

ernstcs
Contributor III

Are these settings needing to be set for users that already have a local profile, or for new users logging on to a system the first time? And to be clear you want to set the default browser they use AND their home page? Which browser do you want to be the default?

Do you use a JSS to image your systems using configurations?

Craig E

Not applicable

The end users already have local accounts and they have their homepages set according to their personal tastes etc.. We need to launch a new internal website and switch end user settings for both homepage and default browser to Safari (or anything else for that matter) without wiping out their current other settings like default download location, autofill, tabs etc.. Of course moving forward we can alter the new user template to include the changes we want- catching the other 450+ users up to speed is the tricky part.

AlanR

milesleacy
Valued Contributor

The proverbial "little bird" told me that there's a fifth way to set your
home page...
Type "jamf help setHomePage" on a Casper-managed machine. You can fill the
user template and existing users with this command.

----------
Miles A. Leacy IV

? Certified System Administrator 10.4
? Certified Technical Coordinator 10.5
? Certified Trainer
Certified Casper Administrator
----------
voice: 1-347-277-7321
miles.leacy at themacadmin.com
www.themacadmin.com

tlarkin
Honored Contributor

That won't work for firefox will it? I think firefox has it's own set
of self contained preferences that have to be configured in firefox. You could probably use an apple script to set it though.

ernstcs
Contributor III

That's why he also wants to force the default browser to Safari. =)

Not applicable

This is what I have set

jamf setHomePage -feu -fet -homepage https://yahoo.com//
-- Enrique 'Ricky' Silberg | IT Director Macintosh Services
285 Madison Avenue, New York, New York 10017 USA
T: +1 212 210 3683

milesleacy
Valued Contributor

Given that the command has switches to specifically exclude setting the
preference for Firefox and other browsers, I assume it sets the preference
in all browsers by default (or at least all of the ones mentioned in the
help).

----------
Miles A. Leacy IV

? Certified System Administrator 10.4
? Certified Technical Coordinator 10.5
? Certified Trainer
Certified Casper Administrator
----------
voice: 1-347-277-7321
miles.leacy at themacadmin.com
www.themacadmin.com

Not applicable

Alright, Using the hints you all have provided I created a mini script with a single string of code.

jamf setHomePage -feu -fet -ffmstone -mozmstone -homepage http://fooisfoo.com/

And sent that to my test computer. As specified in the help I am covering Firefox with -ffmstone and mozilla with -mozmstone in the string. The added argument to change the user template will make the changes for any new accounts created.

Checking the settings of the test computer reveals the homepage change was successful!

Now I need to affect the browser default but I don't see that option- Applescript is not a very 'silent' way to make such changes but I'm not shy about using it.

tlarkin
Honored Contributor

For those of you that want to package and deploy firefox in a managed
manner, I highly suggest a firefox add on called Public Fox. Then
create start up items to not allow users to delete their firefox pref
files from the ~/Library/Application Support/ directory. Or you can
script the install to hide that folder after it is created by either
putting a dot in front of the folder name or using the chflags command.

Public Fox locks down the firefox preferences with a password so that
end users can't change it. If they delete their app support folder and
relaunch the app I think it goes back to default settings.

I have packaged that with composer and a few scripts in the past and it
has worked all right.



Thomas Larkin
TIS Department
KCKPS USD500
tlarki at kckps.org
blackberry: 913-449-7589
office: 913-627-0351

Not applicable

Currently I run this as a policy and it does it to all user accounts on the
computer see 'Setting homepage for'below. We switch homepages on occasion in
addition we have several different company brandings.

jamf setHomePage -feu -fet -homepage https://website.com//
When run this is what log returns

Running command jamf setHomePage -feu -fet -homepage https://website.com
com// (as root)...
Result of jamf setHomePage -feu -fet -homepage https://website.com//:
Setting homepage for Maria...
Updating com.apple.internetconfigpriv.plist...
Updating com.apple.Safari.plist...
Updating com.apple.internetconfig.plist...
Updating /Users//Maria/Library/Application
Support/Firefox/Profiles/kwec0s9o.default/prefs.js...
Setting homepage for mac...
Updating com.apple.internetconfigpriv.plist...
Updating com.apple.Safari.plist...
Updating com.apple.internetconfig.plist...
Updating /Users//mac/Library/Application
Support/Firefox/Profiles/pfsn24qv.default/prefs.js...
Setting homepage for silberge...
Updating com.apple.internetconfigpriv.plist...
Updating com.apple.Safari.plist...
Updating com.apple.internetconfig.plist...
Setting homepage for test...
Updating com.apple.internetconfigpriv.plist...
Updating com.apple.Safari.plist...
Updating com.apple.internetconfig.plist...
Updating receipts...
Finished.
-- Enrique 'Ricky' Silberg | IT Director Macintosh Services
285 Madison Avenue, New York, New York 10017 USA
T: +1 212 210 3683

milesleacy
Valued Contributor

com.apple.LaunchServices.plist contains the default browser settings. It
references the browser by it's bundle identifier.
----------
Miles A. Leacy IV

? Certified System Administrator 10.4
? Certified Technical Coordinator 10.5
? Certified Trainer
Certified Casper Administrator
----------
voice: 1-347-277-7321
miles.leacy at themacadmin.com
www.themacadmin.com