How do I synchronize sites/default/files wtith a AmazonS3 bucket?
If the need is to occasionally copy files from a directory to a corresponding directory on S3, you can use S3 CLI from AWS.

It provides a recursive copy:
aws s3 cp /tmp/foo s3://bucket/ --recursive


Reference: s3 — AWS CLI 1.2.13 documentation : http://docs.aws.amazon.com/cli/latest/reference/s3/

I programatically called this once using the shell-exec from python and invoking the CLI commands. 

The long route require the use of AWS S3 REST API (or one of the client SDKs). I havent done this myself, but it is possible since the CLI itself is implemented this way. May be you can take a look at the CLI code on github