We have a spring cloud function deployed on AWS lambda. How can we get spring-cloud-aws-autoconfigure to work without access key and secret key, assuming the keys set by the lambda execution role instead?
If we use the autoconfigure, it always throws:
org.springframework.beans.factory.UnsatisfiedDependencyException:
Error creating bean with name
'org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaConfiguration':
Unsatisfied dependency expressed through constructor parameter 0;
nested exception is
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'tarodb': Invocation of init method failed;
nested exception is com.amazonaws.SdkClientException: Unable to load
AWS credentials from any provider in the chain:
[com.amazonaws.auth.EC2ContainerCredentialsProviderWrapper@7e990ed7:
Unable to load credentials from service endpoint,
com.amazonaws.auth.profile.ProfileCredentialsProvider@821330f: profile
file cannot be null]
Thanks