Files
fedora-OEMDRV/system_setup/mount_nocrypt_home.sh
T
2026-03-08 18:41:26 +01:00

33 lines
1.0 KiB
Bash
Executable File

#!/bin/sh
# SPDX-FileCopyrightText: Daniel Pätzold
# SPDX-License-Identifier: AGPL-3.0-or-later
#
# 30.12.2025 - Currently, the basic Encryption- System of FreeIPA is NOT WORKING due to failing KRA- Install at FreeIPA
# I created an Issue for that: https://github.com/dogtagpki/pki/issues/5242
# So we will skip encryption completely!
source $(dirname "$0")/setup_system.inc.sh
EXECDIR=$(pwd)
#Check if Directory is alread mounted
grep ${DECRYPTEDDATADIR} /etc/mtab >/dev/null
if [ $? -eq 0 ]; then
#Directory is already mounted
echo "It looks like the directory is already mounted. Not mounting again."
exit 0
fi
#Setup and use encrypted filesystem
if [ ! -d "${DECRYPTEDDATADIR}" ]; then
#Key has been obtained, but no Directory was created till know
echo "First Setup of encryption: Creating new Directories now"
mkdir -p ${DECRYPTEDDATADIR}
if [ $? -eq 0 ]; then
echo "Sucessfully mounted encrypted private Directory ${DECRYPTEDDATADIR}"
exit 0
else
echo "Errorcode ${RETAVAL}"
exit 1
fi
fi