fix: Correct issue with user setup script execution check

This commit is contained in:
Kyle Gospodnetich 2024-02-27 18:29:45 -08:00
parent e980853e3c
commit 93bc12f304

View File

@ -28,8 +28,8 @@ USER_SETUP_FEDORA_VER_RAN=$(cat $USER_SETUP_FEDORA_VER_FILE)
USER_SETUP_IMAGE_VER_RAN=$(cat $USER_SETUP_IMAGE_VER_FILE)
# Run script if updated
if [[ -f $USER_SETUP_VER_FILE && $USER_SETUP_VER = $USER_SETUP_VER_RAN ]]; then
if [[ -f $USER_SETUP_FEDORA_VER_FILE && $FEDORA_VERSION = $USER_SETUP_FEDORA_VER_RAN && $BASE_IMAGE_NAME == USER_SETUP_IMAGE_VER_RAN ]]; then
if [[ -f $USER_SETUP_VER_FILE && -f $USER_SETUP_FEDORA_VER_RAN && -f $USER_SETUP_FEDORA_VER_FILE ]]; then
if [[ $USER_SETUP_VER = "$USER_SETUP_VER_RAN" && $FEDORA_VERSION = "$USER_SETUP_FEDORA_VER_RAN" && $BASE_IMAGE_NAME = "$USER_SETUP_IMAGE_VER_RAN" ]]; then
echo "User setup v$USER_SETUP_VER has already run. Exiting..."
exit 0
fi