title: read tar.gz file into binary string python
body: <p>I have to upload a tar ball (tar.gz) file into s3 but by calling internal API. </p>
  
  <p>The API accepts base64 encoded string. </p>
  
  <p>Is there a way to convert tar.gz file to bytes string and then convert to base64 string in python?</p>