title: aws s3 replace file atomically
body: <h3>Environment</h3>
  <ul>
  <li><p>I copied a file, <code>./barname.bin</code>, to s3, using the command <code>aws s3 cp ./barname.bin s3://fooname/barname.bin</code></p>
  </li>
  <li><p>I have a different file, <code>./barname.1.bin</code> that I want to upload <em>in place of</em> that file</p>
  </li>
  </ul>
  <hr />
  <p>How can I upload and replace (overwrite) the file at <code>s3://fooname/barname.bin</code> with <code>./barname.1.bin</code>?</p>
  <h3>Goals:</h3>
  <ul>
  <li>Don't change the s3 url used to access the file (new file should also be available at <code>s3://fooname/barname.bin</code>).</li>
  <li>zero/minimum 'downtime'/unavailability of the s3 link.</li>
  </ul>