Podešavanje načina rada jedne aplikacije

Način rada s jednom aplikacijom prilagođena je GNOME ljuska koja podešava ljusku kao interaktivni kiosk. Administrator zaključava određena ponašanja kako bi standardnu radnu površinu učinio restriktivnijom za korisnike, dopuštajući im da se usredotoče na odabrane značajke.

Postavite način rada s jednom aplikacijom za širok raspon funkcija u brojnim poljima (od komunikacije do zabave ili obrazovanja) i koristite ga kao samouslužni stroj, upravitelj događaja, mjesto registracije itd.

Your distribution might provide the GNOME Kiosk session, which is usually available in the gnome-kiosk package. You can use it to configure single-application mode more easily. Otherwise, use the following procedure.

Postavljanje načina rada jedne aplikacije

  1. Zaključajte postavke kako bi spriječili ispis, pristup terminalu itd..

  2. Podesite automatsku prijavu u /etc/gdm/custom.conf datoteci za korisnika.

    Pogledajte Podešavanje automatske prijave za više informacija.

  3. Create the following files with the listed content:

    /usr/share/applications/org.gnome.Kiosk.Script.desktop
    [Desktop Entry]
    Name=Kiosk
    Type=Application
    Exec=gnome-kiosk
    /usr/share/applications/org.gnome.Kiosk.WindowManager.desktop
    [Desktop Entry]
    Type=Application
    Name=Mutter
    Comment=Window manager
    Exec=/usr/bin/mutter
    Categories=GNOME;GTK;Core;
    OnlyShowIn=GNOME;
    NoDisplay=true
    X-GNOME-Autostart-Phase=DisplayServer
    X-GNOME-Provides=windowmanager;
    X-GNOME-Autostart-Notify=true
    X-GNOME-AutoRestart=false
    X-GNOME-HiddenUnderSystemd=true
    /usr/share/gnome-session/sessions/gnome-kiosk.session
    [GNOME Session]
    Name=Kiosk
    RequiredComponents=org.gnome.Kiosk.WindowManager;org.gnome.Kiosk.Script;
    /usr/share/X11/xorg.conf.d/20-gnome-kiosk.conf
    Section "ServerFlags"
        Option "DontVTSwitch" "on"
    EndSection
    /usr/share/xsessions/org.gnome.Kiosk.desktop
    [Desktop Entry]
    Name=Kiosk
    Comment=Kiosk mode
    Exec=/usr/bin/gnome-session --session=gnome-kiosk
    DesktopNames=GNOME-Kiosk;GNOME;
  4. As the user that will open the single-application session, create the /home/user/.local/bin/gnome-kiosk file:

    [user]$ mkdir -p ~/.local/bin
    
    [user]$ touch ~/.local/bin/gnome-kiosk
  5. Edit the /home/user/.local/bin/gnome-kiosk file and enter the executable name of the application that you want to launch in single-application mode.

    For example, to launch the Firefox browser in single-application mode, enter the following content:

    #!/bin/sh
    
    while true; do
        firefox --kiosk https://example.org
    done

    The while true loop ensures that the application restarts if it terminates for any reason.

  6. Make the file executable:

    [user]$ chmod +x ~/.local/bin/gnome-kiosk
  7. If you created the file or its containing directories as a different user than the single-application user, such as root, ensure that the file has the correct permissions:

    # chown -R user:group ~user/.local
  8. At the GNOME login screen, select the Kiosk session from the gear button menu and log in as the single-application user.