Files
runner-images/images/linux/scripts/installers/post-deployment.sh
Leonid Lapshin 9d8d110fcf typo
2020-11-04 00:42:36 +03:00

28 lines
722 B
Bash

#!/bin/bash -e
################################################################################
## File: post-deployment.sh
## Desc: Post deployment actions
################################################################################
mv -f /imagegeneration/post-generation /opt
# set chmod -R 777 /opt
if [[ -d "/opt" ]]; then
echo "chmod -R 777 /opt"
chmod -R 777 /opt
fi
# remove installer and helper folders
rm -rf $HELPER_SCRIPT_FOLDER
rm -rf $INSTALLER_SCRIPT_FOLDER
chmod 755 $IMAGE_FOLDER
# Remove quotes around PATH
PATH=${PATH#"\""}
PATH=${PATH%"\""}
echo "PATH=$PATH" | sudo tee -a /etc/environment
echo "Updated PATH: $PATH"
# Clean yarn and npm cache
yarn cache clean
npm cache clean --force