Update apply.sh

Updated BASE_DIR variable from `pwd` to `pwd -P` to resolve symbolic linking.