title: localstack: aws cp fails to upload file to S3 bucket
body: <p>I launched a Docker container for the image <code>localstack/localstack:0.12.9.1</code>.
  I opened the internal shell of this container by the command:</p>
  <pre><code>docker exec -it &lt;container-name&gt; sh
  </code></pre>
  <p>The next thing I wanted to do is to upload a file to S3 bucket.</p>
  <p>I executed the command:</p>
  <pre><code>aws s3 cp /my-file.txt s3://my-bucket/. --region local --endpoint-url=http://local
  stack:4566
  </code></pre>
  <p>and I got the error message:</p>
  <blockquote>
  <p>upload failed: ../../../my-file.txt to
  s3://my-bucket/. An error occurred (500) when calling
  the PutObject operation (reached max retries: 4): Internal Server
  Error</p>
  </blockquote>
  <p>To be sure that this bucket exists, I executed the command:</p>
  <pre><code>aws s3api list-buckets --region local --endpoint-url=http://localstack:4566
  </code></pre>
  <p>and I got:</p>
  <pre><code>{
      &quot;Buckets&quot;: [
          {
              &quot;Name&quot;: &quot;my-bucket&quot;,
              &quot;CreationDate&quot;: &quot;2021-05-14T14:23:03.000Z&quot;
          }
      ],
      &quot;Owner&quot;: {
          &quot;DisplayName&quot;: &quot;webfile&quot;,
          &quot;ID&quot;: &quot;bcaf1ffd86f41161ca5fb16fd081034f&quot;
      } 
  }
  </code></pre>
  <p>So the problem is not that the bucket is missing.</p>
  <p>Do you know why I cannot upload file to S3?</p>