Using an HTTP Proxy
If you need to access AWS through proxy servers, you should configure the
HTTP_PROXY and HTTPS_PROXY environment variables with the IP
addresses for your proxy servers.
Linux, OS X, or Unix
$ export HTTP_PROXY=http://a.b.c.d:n
$ export HTTPS_PROXY=http://w.x.y.z:mWindows
> set HTTP_PROXY=http://a.b.c.d:n
> set HTTPS_PROXY=http://w.x.y.z:m In these examples, http://a.b.c.d:n and http://w.x.y.z:m are
the IP addresses and ports for the HTTP and HTTPS proxies.
Authenticating to a Proxy
The AWS CLI supports HTTP Basic authentication. Specify a username and password in the proxy URL like this:
Linux, OS X, or Unix
$ export HTTP_PROXY=http://username:password@a.b.c.d:n
$ export HTTPS_PROXY=http://username:password@w.x.y.z:mWindows
> set HTTP_PROXY=http://username:password@a.b.c.d:n
> set HTTPS_PROXY=http://username:password@w.x.y.z:mNote
The AWS CLI does not support NTLM proxies.
Using a proxy on EC2 Instances
If you configure a proxy on an ec2 instance launched with an IAM role, you should
also set the NO_PROXY environment variable with the IP address 169.254.169.254,
so that the AWS CLI can access the Instance Meta Data Service (IMDS).
Linux, OS X, or Unix
$ export NO_PROXY=169.254.169.254Windows
> set NO_PROXY=169.254.169.254


