title: Uploaded file in ec2 instances should be transferd to s3 automatically
body: <p>I have a website hosted on ec2 instance(tomcat) and it has an upload image facility. My intention is to switch to CloudFront to reduce the load time of the website. Images on the website are loaded from a directory called "images" and the name of images are stored in database. when a page is loaded the name of the image is loaded from database and then the image is loaded. I can copy the images directory to s3 instance manually. However when an image is uploaded, a entry in database is made, but the "images" directory in s3 instance remain outdated. Need something so that s3 directory updates as soon as image is uploaded. I am new to s3 and CloudFront. Pleas Help! </p>