Fix permissions
Support uploading .tgz files