Update file run_onchange_after_45-vmware.tmpl

This commit is contained in:
Brian Zalewski 2023-02-01 06:56:51 +00:00
parent 4250f4d220
commit 99efcdc240

View file

@ -13,19 +13,31 @@ if command -v vmware > /dev/null; then
VMW_VERSION=$(vmware --version | cut -f 3 -d' ') VMW_VERSION=$(vmware --version | cut -f 3 -d' ')
mkdir -p /tmp/vmw_patch mkdir -p /tmp/vmw_patch
cd /tmp/vmw_patch cd /tmp/vmw_patch
curl https://github.com/mkubecek/vmware-host-modules/archive/workstation-$VMW_VERSION.tar.gz -o /tmp/vmw_patch/workstation.tar.gz logg info 'Downloading VMWare host module patches'
curl -sSL https://github.com/mkubecek/vmware-host-modules/archive/workstation-$VMW_VERSION.tar.gz -o /tmp/vmw_patch/workstation.tar.gz
tar -xzf /tmp/vmw_patch/workstation.tar.gz tar -xzf /tmp/vmw_patch/workstation.tar.gz
logg info 'Running `sudo make` and `sudo make install`'
sudo make sudo make
sudo make install sudo make install
logg success 'Successfully configured VMWare host module patches'
fi fi
###Install Unlocker ### Patch VMWare with Unlocker
UNLOCKER_URL=$(curl https://api.github.com/repos/DrDonk/unlocker/releases/latest | jq -r '.assets[0].browser_download_url') if [ ! -f /usr/lib/vmware/isoimages/darwin.iso ]; then
mkdir -p /tmp/vmw_unlocker logg info 'Acquiring VMWare Unlocker latest release version'
cd /tmp/vmw_unlocker UNLOCKER_URL=$(curl -sSL https://api.github.com/repos/DrDonk/unlocker/releases/latest | jq -r '.assets[0].browser_download_url')
curl $UNLOCKER_URL -o /tmp/vmw_unlocker/unlocker.zip mkdir -p /tmp/vmware-unlocker
unzip /tmp/vmw_unlocker/unlocker.zip cd /tmp/vmware-unlocker
echo "y" | sudo ./unlock logg info 'Downloading unlocker.zip'
curl -sSL "$UNLOCKER_URL" -o unlocker.zip
unzip unlocker.zip
cd linux
logg info 'Running the unlocker'
echo "y" | sudo ./unlock
logg success 'Successfully unlocked VMWare for macOS compatibility'
else
logg info '/usr/lib/vmware/isoimages/darwin.iso is already present on the system so VMWare macOS unlocking will not be performed'
fi
else else
logg warn 'VMware Workstation is not installed so the VMware Unlocker will not be installed' logg warn 'VMware Workstation is not installed so the VMware Unlocker will not be installed'
fi fi