can't use ruby Tempfile due to permission issue, create temp file with a uniue name