Automated Firefox install via ansible | User profiles & extensions

32 views
Skip to first unread message

FelixN

unread,
Jun 24, 2022, 12:43:33 PMJun 24
to enter...@mozilla.org
Hello,
I have a question regarding generating user profiles for a user that has never logged in for a firefox that has never been launched.
I posted this on reddit and the only answer I got suggested, I ask here. If that's not what this is for, I apologize. 
Anyway, I'll paste my reddit post here and i would appreciate if anyone could clarify things to me.

Hello,

I'm in the process of writing ansible in order to install firefox esr on debian11 on several machines. I want the browser to have certain configurations for the users who will be using it. I wrote a user.js that should do all that.

Question now is: How do I set the profiles right? They should get created automatically the first time firefox is started. But I want to do it in my script before it's ever launched and put my user.js in there. Now I've read that the profile folders have automatically generated names. I think i cant just create folders and treat them like a profile folder, can i? Can anyone help me out?

On top: I also want to install certain extensions completely automatically and non-interactive. Any tips?


https://www.reddit.com/r/firefox/comments/vjpv0a/automated_firefox_install_via_ansible_user/

Thank you :)
Felix

Luca Olivetti

unread,
Jun 25, 2022, 6:29:15 PMJun 25
to enter...@mozilla.org
El 24/6/22 a les 18:43, FelixN ha escrit:

> Now I've read that the profile folders have automatically generated
> names. I think i cant just create folders and treat them like a profile
> folder, can i? Can anyone help me out?

You can override the auto-generated name by creating a suitable
profile.ini (see the one that's auto-generated and modify to taste).
Of course I don't know how long this will be available though, since it
seems mozilla is removing useful features all the time.

>
> On top: I also want to install certain extensions completely
> automatically and non-interactive. Any tips?

Once upon a time it was easy (well, not that easy, there were some
hurdles with autodisablescopes): just put them alongside the executable
in an "extensions" or "browser/extensions" directory (depending on the
firefox vintage).
Sadly that is no longer possible, but at least you can use policies.json
https://support.mozilla.org/en-US/kb/customizing-firefox-using-policiesjson
More convoluted but, when the stars align, it works. If the user can
download them from the internet or a local server. And if it is
acceptable that the extensions are installed the first time the user
opens firefox, so they aren't available until then (guess what: I have
an extension where that isn't acceptable, but it's for thunderbird, not
for firefox).


Bye
--
Luca Olivetti
Wetron Automation Technology http://www.wetron.es/
Tel. +34 93 5883004 (Ext.3010) Fax +34 93 5883007

FelixN

unread,
Jun 27, 2022, 11:42:58 AMJun 27
to enter...@mozilla.org, Luca Olivetti
Thanks, I feared as much. I really wanted to install extensions :( I'll see if I get by with the policies.json, I guess I'll chuck the user.js i prepared right into the trash can.
Why would they get rid of such a great feature I wonder? 
Anyway, thank you very much for your reply.

Cheers
Felix

Mike Kaply

unread,
Jun 27, 2022, 11:50:09 AMJun 27
to FelixN, enter...@mozilla.org, Luca Olivetti
You could use the distribution directory to install the extensions.


Mike

--
You received this message because you are subscribed to the Google Groups "enter...@mozilla.org" group.
To unsubscribe from this group and stop receiving emails from it, send an email to enterprise+...@mozilla.org.
To view this discussion on the web visit https://groups.google.com/a/mozilla.org/d/msgid/enterprise/5113e61d-9459-48e6-9152-c184239e4dfan%40mozilla.org.

Paul Kosinski

unread,
Jun 27, 2022, 12:27:53 PMJun 27
to enter...@mozilla.org, FelixN
On Mon, 27 Jun 2022 08:42:58 -0700 (PDT)
FelixN <der.wei...@gmail.com> wrote:

>> Why would they get rid of such a great feature I wonder?
>
> Cheers
> Felix


Because Chrome doesn't have it?

Mike Kaply

unread,
Jun 27, 2022, 12:35:21 PMJun 27
to Paul Kosinski, Mozilla.org, FelixN
If you're referring to extension scopes, those still work.

Mike
 

--
You received this message because you are subscribed to the Google Groups "enter...@mozilla.org" group.
To unsubscribe from this group and stop receiving emails from it, send an email to enterprise+...@mozilla.org.

FelixN

unread,
Jun 29, 2022, 7:10:21 AMJun 29
to enter...@mozilla.org, mka...@mozilla.com, Mozilla.org, FelixN, Paul Kosinski
Thank you folks, esp. mkaply, this was really helpful. I was able to achieve everything I wanted. 

Cheer's

Reply all
Reply to author
Forward
0 new messages