title: Upload image from EC2 to S3
body: <p>Please excuse my English, i'm French :)</p>
  
  <p>So, I've to upload images from ec2 to s3.
  I'm using the php library but I find it very, very loooong !
  So, I've made some search and I've find the s3cmd tool.
  But it doesn't work with exec php function :</p>
  
  <pre><code>exec("/usr/bin/s3cmd  put –acl-public –guess-mime-type  –config=/var/www/html/.s3cfg   /var/www/html/website/public/img/a/1380098080346/1.jpg  s3://mybucket  2&gt;&amp;1")
  </code></pre>
  
  <p>The output is :</p>
  
  <pre><code>ERROR: Can't find a config file. Please use --config option.
  </code></pre>
  
  <p>My config file's owner is apache, and rights are 777 (for testing ;)) but nothing...
  I still have the same error...</p>
  
  <p>For information I've followed this page : <a href="http://thephpsolutions.wordpress.com/tag/s3cmd/" rel="nofollow">http://thephpsolutions.wordpress.com/tag/s3cmd/</a></p>
  
  <p>Have you got an idea ?
  Thanks a lot !</p>