search-app: Add systemd session files
Resolves: https://issues.redhat.com/browse/RHEL-82404
This commit is contained in:
parent
a815251f40
commit
807120a20d
68
0001-search-app-Add-systemd-session-files.patch
Normal file
68
0001-search-app-Add-systemd-session-files.patch
Normal file
@ -0,0 +1,68 @@
|
|||||||
|
From fea0d74ff155f05e9f1e8e0351562af6c7c15b3c Mon Sep 17 00:00:00 2001
|
||||||
|
From: Olivier Fourdan <ofourdan@redhat.com>
|
||||||
|
Date: Tue, 4 Mar 2025 16:21:30 +0100
|
||||||
|
Subject: [PATCH 1/2] search-app: Add systemd session files
|
||||||
|
|
||||||
|
The search appliance session would fail to start as a systemd session.
|
||||||
|
|
||||||
|
Add the required systemd plumbing to fix the search appliance session.
|
||||||
|
|
||||||
|
Part-of: <https://gitlab.gnome.org/GNOME/gnome-kiosk/-/merge_requests/66>
|
||||||
|
|
||||||
|
(cherry picked from commit a40ac8d8dc132d9c94506419158ec4034eaaf2c8)
|
||||||
|
---
|
||||||
|
meson.build | 12 ++++++++++++
|
||||||
|
.../systemd/org.gnome.Kiosk.SearchApp.service.in | 8 ++++++++
|
||||||
|
search-app/systemd/session.conf | 3 +++
|
||||||
|
3 files changed, 23 insertions(+)
|
||||||
|
create mode 100644 search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
create mode 100644 search-app/systemd/session.conf
|
||||||
|
|
||||||
|
diff --git a/meson.build b/meson.build
|
||||||
|
index fb9a76d..2024b76 100644
|
||||||
|
--- a/meson.build
|
||||||
|
+++ b/meson.build
|
||||||
|
@@ -350,5 +350,17 @@ i18n.merge_file(
|
||||||
|
type: 'desktop'
|
||||||
|
)
|
||||||
|
|
||||||
|
+configure_file(
|
||||||
|
+ input: 'search-app/systemd/org.gnome.Kiosk.SearchApp.service.in',
|
||||||
|
+ output: '@BASENAME@',
|
||||||
|
+ configuration: systemd_service_config_data,
|
||||||
|
+ install_dir: systemd_user_unit_dir
|
||||||
|
+)
|
||||||
|
+
|
||||||
|
+kiosk_search_appliance_systemd_target_dir = join_paths(systemd_user_unit_dir, 'gnome-session@org.gnome.Kiosk.SearchApp.target.d')
|
||||||
|
+install_data('search-app/systemd/session.conf',
|
||||||
|
+ install_dir: kiosk_search_appliance_systemd_target_dir
|
||||||
|
+)
|
||||||
|
+
|
||||||
|
test('check-format', find_program('scripts/check-format.sh'))
|
||||||
|
|
||||||
|
diff --git a/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in b/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000..29ddcd8
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
@@ -0,0 +1,8 @@
|
||||||
|
+[Unit]
|
||||||
|
+Description=Kiosk Search Appliance
|
||||||
|
+BindsTo=gnome-session.target
|
||||||
|
+After=gnome-session.target
|
||||||
|
+
|
||||||
|
+[Service]
|
||||||
|
+ExecStart=@bindir@/firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
|
+Restart=always
|
||||||
|
diff --git a/search-app/systemd/session.conf b/search-app/systemd/session.conf
|
||||||
|
new file mode 100644
|
||||||
|
index 0000000..1ab41da
|
||||||
|
--- /dev/null
|
||||||
|
+++ b/search-app/systemd/session.conf
|
||||||
|
@@ -0,0 +1,3 @@
|
||||||
|
+[Unit]
|
||||||
|
+Requires=org.gnome.Kiosk.target
|
||||||
|
+Requires=org.gnome.Kiosk.SearchApp.service
|
||||||
|
--
|
||||||
|
2.48.1
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From fb932adc99bb0b73567674ff905782a642b9b12e Mon Sep 17 00:00:00 2001
|
From bad81e556eca3acad1b97f6dbc00f3788e24d25f Mon Sep 17 00:00:00 2001
|
||||||
From: Olivier Fourdan <ofourdan@redhat.com>
|
From: Olivier Fourdan <ofourdan@redhat.com>
|
||||||
Date: Thu, 12 Dec 2024 14:05:04 +0100
|
Date: Thu, 12 Dec 2024 14:05:04 +0100
|
||||||
Subject: [PATCH] search-app: Use firefox from flatpak
|
Subject: [PATCH] search-app: Use firefox from flatpak
|
||||||
@ -9,10 +9,11 @@ appliance to use flatpak instead of invoking firefox directly.
|
|||||||
https://issues.redhat.com/browse/RHEL-36521
|
https://issues.redhat.com/browse/RHEL-36521
|
||||||
---
|
---
|
||||||
search-app/org.gnome.Kiosk.SearchApp.desktop.in.in | 2 +-
|
search-app/org.gnome.Kiosk.SearchApp.desktop.in.in | 2 +-
|
||||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
search-app/systemd/org.gnome.Kiosk.SearchApp.service.in | 2 +-
|
||||||
|
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
diff --git a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
diff --git a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
index 360e6df..4416353 100644
|
index 478b328..ad142b8 100644
|
||||||
--- a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
--- a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
+++ b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
+++ b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
@@ -2,7 +2,7 @@
|
@@ -2,7 +2,7 @@
|
||||||
@ -21,9 +22,20 @@ index 360e6df..4416353 100644
|
|||||||
Comment=Sample Search Appliance Application for GNOME Kiosk
|
Comment=Sample Search Appliance Application for GNOME Kiosk
|
||||||
-Exec=@bindir@/firefox --kiosk --private-window --new-instance https://www.google.com
|
-Exec=@bindir@/firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
+Exec=@bindir@/flatpak run --command=firefox --file-forwarding org.mozilla.firefox --kiosk --private-window --new-instance https://www.google.com
|
+Exec=@bindir@/flatpak run --command=firefox --file-forwarding org.mozilla.firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
Categories=GNOME;GTK;Core;
|
Categories=Core;System;
|
||||||
OnlyShowIn=GNOME;
|
|
||||||
NoDisplay=true
|
NoDisplay=true
|
||||||
--
|
X-GNOME-HiddenUnderSystemd=true
|
||||||
2.47.1
|
diff --git a/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in b/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
index 29ddcd8..d4f5d0f 100644
|
||||||
|
--- a/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
+++ b/search-app/systemd/org.gnome.Kiosk.SearchApp.service.in
|
||||||
|
@@ -4,5 +4,5 @@ BindsTo=gnome-session.target
|
||||||
|
After=gnome-session.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
-ExecStart=@bindir@/firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
|
+ExecStart=@bindir@/flatpak run --command=firefox --file-forwarding org.mozilla.firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
|
Restart=always
|
||||||
|
--
|
||||||
|
2.48.1
|
||||||
|
|
||||||
|
32
0002-search-app-Update-desktop-file-definition.patch
Normal file
32
0002-search-app-Update-desktop-file-definition.patch
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
From 30d48384d2b98dc6ba9534ef41ce445f6da41d7f Mon Sep 17 00:00:00 2001
|
||||||
|
From: Olivier Fourdan <ofourdan@redhat.com>
|
||||||
|
Date: Wed, 5 Mar 2025 14:23:49 +0100
|
||||||
|
Subject: [PATCH 2/2] search-app: Update desktop file definition
|
||||||
|
|
||||||
|
Firefox itself has nothing to do with neither Gtk or GNOME, no need to
|
||||||
|
list those in the categories.
|
||||||
|
|
||||||
|
Part-of: <https://gitlab.gnome.org/GNOME/gnome-kiosk/-/merge_requests/66>
|
||||||
|
|
||||||
|
(cherry picked from commit 5441999573a07c3513eeda5150683448bdd71c50)
|
||||||
|
---
|
||||||
|
search-app/org.gnome.Kiosk.SearchApp.desktop.in.in | 5 ++---
|
||||||
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
|
index 360e6df..478b328 100644
|
||||||
|
--- a/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
|
+++ b/search-app/org.gnome.Kiosk.SearchApp.desktop.in.in
|
||||||
|
@@ -3,7 +3,6 @@ Type=Application
|
||||||
|
Name=Search Appliance
|
||||||
|
Comment=Sample Search Appliance Application for GNOME Kiosk
|
||||||
|
Exec=@bindir@/firefox --kiosk --private-window --new-instance https://www.google.com
|
||||||
|
-Categories=GNOME;GTK;Core;
|
||||||
|
-OnlyShowIn=GNOME;
|
||||||
|
+Categories=Core;System;
|
||||||
|
NoDisplay=true
|
||||||
|
-X-GNOME-AutoRestart=true
|
||||||
|
+X-GNOME-HiddenUnderSystemd=true
|
||||||
|
--
|
||||||
|
2.48.1
|
||||||
|
|
@ -41,14 +41,18 @@ BuildRequires: pkgconfig(gdk-pixbuf-2.0)
|
|||||||
Requires: gnome-settings-daemon%{?_isa} >= %{gnome_settings_daemon_version}
|
Requires: gnome-settings-daemon%{?_isa} >= %{gnome_settings_daemon_version}
|
||||||
Requires: gsettings-desktop-schemas%{?_isa} >= %{gsettings_desktop_schemas_version}
|
Requires: gsettings-desktop-schemas%{?_isa} >= %{gsettings_desktop_schemas_version}
|
||||||
|
|
||||||
Patch0: 0001-kiosk-app-Do-not-add-the-window-in-kiosk_app_new_for.patch
|
Patch: 0001-kiosk-app-Do-not-add-the-window-in-kiosk_app_new_for.patch
|
||||||
# https://issues.redhat.com/browse/RHEL-36521
|
|
||||||
Patch1: 0001-search-app-Use-firefox-from-flatpak.patch
|
|
||||||
# https://issues.redhat.com/browse/RHEL-71757
|
# https://issues.redhat.com/browse/RHEL-71757
|
||||||
Patch2: 0001-kiosk-script-Copy-and-run-the-script-from-XDG_RUNTIM.patch
|
Patch: 0001-kiosk-script-Copy-and-run-the-script-from-XDG_RUNTIM.patch
|
||||||
# https://issues.redhat.com/browse/RHEL-62420
|
# https://issues.redhat.com/browse/RHEL-62420
|
||||||
Patch3: 0001-compositor-Add-screenshot-utilities.patch
|
Patch: 0001-compositor-Add-screenshot-utilities.patch
|
||||||
Patch4: 0002-compositor-Add-Shell-Screenshot-support.patch
|
Patch: 0002-compositor-Add-Shell-Screenshot-support.patch
|
||||||
|
# https://issues.redhat.com/browse/RHEL-82250
|
||||||
|
# https://issues.redhat.com/browse/RHEL-82404
|
||||||
|
Patch: 0001-search-app-Add-systemd-session-files.patch
|
||||||
|
Patch: 0002-search-app-Update-desktop-file-definition.patch
|
||||||
|
# https://issues.redhat.com/browse/RHEL-36521
|
||||||
|
Patch: 0001-search-app-Use-firefox-from-flatpak.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
GNOME Kiosk provides a desktop enviroment suitable for fixed purpose, or
|
GNOME Kiosk provides a desktop enviroment suitable for fixed purpose, or
|
||||||
@ -101,6 +105,8 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Kiosk.Searc
|
|||||||
%{_userunitdir}/org.gnome.Kiosk@x11.service
|
%{_userunitdir}/org.gnome.Kiosk@x11.service
|
||||||
|
|
||||||
%files -n gnome-kiosk-search-appliance
|
%files -n gnome-kiosk-search-appliance
|
||||||
|
%{_userunitdir}/gnome-session@org.gnome.Kiosk.SearchApp.target.d/session.conf
|
||||||
|
%{_userunitdir}/org.gnome.Kiosk.SearchApp.service
|
||||||
%{_datadir}/applications/org.gnome.Kiosk.SearchApp.desktop
|
%{_datadir}/applications/org.gnome.Kiosk.SearchApp.desktop
|
||||||
%{_datadir}/gnome-session/sessions/org.gnome.Kiosk.SearchApp.session
|
%{_datadir}/gnome-session/sessions/org.gnome.Kiosk.SearchApp.session
|
||||||
%{_datadir}/xsessions/org.gnome.Kiosk.SearchApp.Session.desktop
|
%{_datadir}/xsessions/org.gnome.Kiosk.SearchApp.Session.desktop
|
||||||
|
Loading…
Reference in New Issue
Block a user