Fix abs path issues when deploying tar.gz files

This is ready to be merged