Red Hat Training

A Red Hat training course is available for Red Hat Enterprise Linux

13.9. Single-application Mode

Single-application mode is a modified shell which reconfigures the shell into an interactive kiosk. The administrator locks down some behavior to make the standard desktop more restrictive for the user, letting them focus on selected features.
Set up single-application mode for a wide range of functions in a number of fields (from communication to entertainment or education) and use it as a self-serve machine, event manager, registration point, etc.

Procedure 13.9. Set Up Single-application Mode

  1. Lock down settings to prevent printing, terminal access, and so on. See:
  2. Configure automatic login in the /etc/gdm/custom.conf file for the user.
  3. Create a new user with a name, which follows typical naming conventions (no space or special characters, do not start with a digit or a dash). Also, make sure the user name matches with the related names, such as when referring to a session. A good example is kiosk-user.
  4. Create a session with a name matching your user name (for example, for our kiosk-user, kiosk is a good match) by writing a /usr/share/xsessions/kiosk.desktop file and setting the Exec line to be:
    Exec=gnome-session --session kiosk
  5. Set the default session for kiosk-user by adding the following line to the /var/lib/AccountsService/users/kiosk-user file.
    XSession=kiosk
  6. Define the kiosk session by writing a custom session definition, containing the following line:
    RequiredComponents=kiosk-app;gnome-settings-daemon;kiosk-shell;
    This creates a session that runs three programs: kiosk-app (a sample application), gnome-settings-daemon (standard component in the GNOME session), and kiosk-shell (which is a customized version of gnome-shell).
  7. Create a desktop file for kiosk-shell, /usr/share/applications/kiosk-shell.desktop, which will contain:
    Exec=gnome-shell --mode=kiosk
  8. Create a mode definition called /usr/share/gnome-shell/modes/kiosk.json. This is a small json file defining the available GNOME Shell UI. (Look at classic.json and initial-setup.json in the same directory as the starting point.)