Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

i wan't to deploy general preferences for all users

  • 1 reply
  • 1 has this problem
  • 2 views
  • Last reply by cor-el

more options

i wan't to deploy general preferences for all users but the all-companyname.js file (as described here: https://developer.mozilla.org/en-US/docs/Mozilla/Preferences/A_brief_guide_to_Mozilla_preferences#Modifying_preferences) doesn't work

Now i've read here (https://developer.mozilla.org/en-US/Firefox/Enterprise_deployment#Changes_Over_Time) that this may changed, but can anyone tell me the correct way witch works with Version 85 ?

My all-company.js file: // lockPref("browser.startup.homepage", "https://www.mysite.ch/"); lockPref("browser.shell.checkDefaultBrowser", false); lockPref("browser.tabs.warnOnClose", false);

i wan't to deploy general preferences for all users but the all-companyname.js file (as described here: https://developer.mozilla.org/en-US/docs/Mozilla/Preferences/A_brief_guide_to_Mozilla_preferences#Modifying_preferences) doesn't work Now i've read here (https://developer.mozilla.org/en-US/Firefox/Enterprise_deployment#Changes_Over_Time) that this may changed, but can anyone tell me the correct way witch works with Version 85 ? My all-company.js file: // lockPref("browser.startup.homepage", "https://www.mysite.ch/"); lockPref("browser.shell.checkDefaultBrowser", false); lockPref("browser.tabs.warnOnClose", false);

All Replies (1)

more options

You can use the mozilla.cfg file in the Firefox program folder to initialize (set/lock) preferences and run privileged JavaScript code.

The mozilla.cfg file needs to be in the main Firefox program folder (Mac).

These functions can be used in mozilla.cfg:

defaultPref();	// set new default value, requires special data: format for localized prefs
pref();	// set pref, allow changes in current session
lockPref();	// lock pref, disallow changes

This requires a local-settings.js file in the "defaults/pref" folder where the channel-prefs.js file is located that specifies to use mozilla.cfg.

//
pref("general.config.filename", "mozilla.cfg");
pref("general.config.obscure_value", 0);

The mozilla.cfg and local-settings.js files need to start with a comment line (//).

See Configuration: