title: Is it possible to execute AWS CLI commands on an EC2 instance without placing AWS credentials on the EC2?
body: <p>I have an API server running on a docker container, and the docker container runs on an <a href="https://aws.amazon.com/tw/ec2/" rel="noreferrer">AWS ec2 instance</a>. </p>
  
  <p>Is it possible to make the server execute <a href="https://aws.amazon.com/cli/" rel="noreferrer">AWS CLI</a> commands without putting my aws credentials on the docker container? </p>
  
  <p>Because I think the aws credentials should only be placed on my local machine. </p>
  
  <p>I don't think it is safe to place it on a remote machine which can be accessed by other people.</p>