Fixed integration with S3

Fixed an error with S3 url interpolating and are now doing temp file creation
the proper way.