Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change location of rescue mode flag file #5680

Merged
merged 1 commit into from
Jul 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Change location of rescue mode flag file
The file indicating that the installer is running is rescue mode needs
to be accessible for %post scripts running in nochroot as well as in
chroot. Create the file in /run/install/, so that both 80-setfilecons.ks
and 99-copy-logs.ks work correctly.

Resolves: RHEL-4794
  • Loading branch information
jstodola committed May 28, 2024
commit 53f41b171bc7f85370b3dfc730c499df73f8914b
2 changes: 1 addition & 1 deletion data/post-scripts/80-setfilecons.ks
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# responsibility (see https://github.com/ostreedev/ostree/pull/872 )
# - OSTree variants of the traditional mounts if present

RESCUE_MODE=/tmp/RESCUE_MODE
RESCUE_MODE=/run/install/RESCUE_MODE

# Do not automatically modify files on the system being rescued.
if [ -e ${RESCUE_MODE} ]; then
Expand Down
2 changes: 1 addition & 1 deletion data/post-scripts/99-copy-logs.ks
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ NOSAVE_INPUT_KS_FILE=/tmp/NOSAVE_INPUT_KS
NOSAVE_LOGS_FILE=/tmp/NOSAVE_LOGS
PRE_ANA_LOGS=/tmp/pre-anaconda-logs
DNF_DEBUG_LOGS=/root/debugdata
RESCUE_MODE=/tmp/RESCUE_MODE
RESCUE_MODE=/run/install/RESCUE_MODE

# Do not copy log files from the rescue environment to the system being rescued to avoid
# rewriting logs from the original installation of the system.
Expand Down
2 changes: 1 addition & 1 deletion pyanaconda/core/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,4 +540,4 @@ class DisplayModes(Enum):
TIMEZONE_PRIORITY_USER = 90

# A flag file indicated the installation is running in rescue mode
RESCUE_MODE_PATH = "/tmp/RESCUE_MODE"
RESCUE_MODE_PATH = "/run/install/RESCUE_MODE"
Loading