nalika / rpms / grub2

Forked from rpms/grub2 2 years ago
Clone

Blame SOURCES/0211-grub-boot-success.timer-Only-run-if-not-in-a-contain.patch

8e15ce
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
8e15ce
From: Gena Makhomed <gmm@csdoc.com>
8e15ce
Date: Thu, 1 Jul 2021 01:07:46 +0200
8e15ce
Subject: [PATCH] grub-boot-success.timer: Only run if not in a container
8e15ce
8e15ce
The grub-boot-success.timer should be disabled inside a container since it
8e15ce
leads to the following error:
8e15ce
8e15ce
Jan 09 22:56:38 test sshd[8786]: pam_unix(sshd:session): session opened for user www(uid=1000) by (uid=0)
8e15ce
Jan 09 22:58:39 test systemd[8857]: Starting Mark boot as successful...
8e15ce
Jan 09 22:58:39 test systemd[8857]: grub-boot-success.service: Main process exited, code=exited, status=1/FAILURE
8e15ce
Jan 09 22:58:39 test systemd[8857]: grub-boot-success.service: Failed with result 'exit-code'.
8e15ce
Jan 09 22:58:39 test systemd[8857]: Failed to start Mark boot as successful.
8e15ce
Jan 09 22:58:39 test grub2-set-bootflag[10034]: Error canonicalizing /boot/grub2/grubenv filename: No such file or directory
8e15ce
8e15ce
Resolves: rhbz#1914571
8e15ce
---
8e15ce
 docs/grub-boot-success.timer | 1 +
8e15ce
 1 file changed, 1 insertion(+)
8e15ce
8e15ce
diff --git a/docs/grub-boot-success.timer b/docs/grub-boot-success.timer
8e15ce
index 5d8fcba21aa..406f1720056 100644
8e15ce
--- a/docs/grub-boot-success.timer
8e15ce
+++ b/docs/grub-boot-success.timer
8e15ce
@@ -1,6 +1,7 @@
8e15ce
 [Unit]
8e15ce
 Description=Mark boot as successful after the user session has run 2 minutes
8e15ce
 ConditionUser=!@system
8e15ce
+ConditionVirtualization=!container
8e15ce
 
8e15ce
 [Timer]
8e15ce
 OnActiveSec=2min