Quantcast
Channel: Active questions tagged amazon-ec2 - Stack Overflow
Viewing all articles
Browse latest Browse all 29250

Force AWS library to obtain region from environment inside docker cluster

$
0
0

I’m trying to test a Java app running in a docker container on my desktop. The app runs fine if I execute it directly from my command line, but it fails when I try to run it inside a Docker container on my desktop. The error output shows that the library is requesting region information, then failing with this error:

com.amazonaws.SdkClientException: Unable to find a region via the region provider chain. Must provide an explicit region in the builder or setup environment to supply a region.

I am providing the region as an environment variable:

AWS_DEFAULT_REGION=us-east-2

If I hard-code the region, it works fine. (The library is successfully extracting the credentials from environment variables.)


Viewing all articles
Browse latest Browse all 29250

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>