1

So I have different firefox profiles that I launch in kiosk mode in order to have small apps for Youtube and Netflix. I saw this problem asked multiple times but I tried other answers and it still doesn't work.

I use a youtube.desktop file that launches firefox with a custom WM_CLASS:

[Desktop Entry]
Name=Youtube
Comment=Launch Youtube in kiosk mode
Type=Application

Exec=firefox --no-remote --new-instance -P "kiosk-youtube" --kiosk --class Firefox-kiosk-youtube https://youtube.com
Terminal=false

Icon=/home/user/.local/share/icons/kiosk-firefox-icons/youtube.png
StartupWMClass=Firefox-kiosk-youtube

Different Firefox profiles are still grouped together and using the basic firefox icon. I'm on GNOME, Ubuntu.

Thanks

1 Answer 1

1

Update (2023-07-07): Removing the -no-remote CLI option avoids the Firefox is already running, but is not responding error.

For me (using Wayland and Gnome 43 on Fedora 37), the catch was to use --name Firefox-kiosk-youtube instead of --class Firefox-kiosk-youtube.

To have GNOME Shell show a nice icon and the contents of Name rather than WM_CLASS (or wmclass) directly, you also need to set StartupWMClass to the same value (e.g. Firefox-kiosk-youtube).

Here is my complete firefox-personal.desktop file:

[Desktop Entry]
Version=1.0
Name=Firefox (Personal)
GenericName=Web Browser
Comment=Browse the Web
Exec=firefox -P personal --name FirefoxPersonal %u
Icon=firefox
Terminal=false
Type=Application
MimeType=text/html;text/xml;application/xhtml+xml;application/vnd.mozilla.xul+xml;text/mml;x-scheme-handler/http;x-scheme-handler/https;
StartupNotify=true
# NOTE: If this is not set to the same as the argument of the --name option,
# then GNOME Shell won't show the nice Firefox icon and the user facing
# "Firefox (Personal)" text along with it.
StartupWMClass=FirefoxPersonal
Categories=Network;WebBrowser;
Keywords=web;browser;internet;
Actions=new-window;new-private-window;profile-manager-window;

X-Desktop-File-Install-Version=0.26

[Desktop Action new-window]
Name=Open a New Window
Exec=firefox -P personal --name FirefoxPersonal --new-window %u

[Desktop Action new-private-window]
Name=Open a New Private Window
Exec=firefox -P personal --name FirefoxPersonal --private-window %u

To verify the WM_CLASS value, one can use GNOME Shell's built-in tool Looking Glass.

Press Alt + F2, type lg and press Enter. In the top-right panel, select "Windows".

The WM_CLASS will be displayed under the wmclass key.

For example: enter image description here

1
  • I'm trying to do this with Gnome 46 on Ubuntu 24.04, but it does not work. It opens a new window, but it is grouped with the other Firefox windows. Looking glass reports wmclass as "FirefoxPersonal", however app is reported like any other Firefox windows as "firefox_firefox.desktop". Any ideas what needs changing? (possibly related topic)
    – fabern
    Commented Jun 26 at 8:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .