title: Java REST service to download file from AWS S3
body: <p>Can some one help me understand this:
  When I deploy my REST service in EC2 server and if the EC2 server has IAM role for S3 access, it will download file from S3.
  What if I am working on my dev/ local environment and trying to access file from S3. I came to know that we need to use, Amazon CLI to access S3 from local environment.
  Can some one explain how my Java code will check for credentials in Amazon CLI(installed in my Mac) to access S3?</p>