Disable Spring Cloud AWS autoconfiguration for local development : <p>I use the following Maven dependency which autoconfigures all necessary parameters to make my project work on AWS:</p>

<pre><code>&lt;dependency&gt;
    &lt;groupId&gt;org.springframework.cloud&lt;/groupId&gt;
    &lt;artifactId&gt;spring-cloud-starter-aws&lt;/artifactId&gt;
    &lt;version&gt;1.2.2.RELEASE&lt;/version&gt;
&lt;/dependency&gt;
</code></pre>

<p>I don't have any critical functionality depending on AWS though, it's just to load a few files from S3 at runtime. So during local development (and also testing), I don't need any AWS autoconfiguration.</p>

<p>The logical error I get when running locally is:</p>

<pre><code>...
Caused by: java.lang.IllegalStateException: There is no EC2 meta data available, because the application is not running in the EC2 environment. Region detection is only possible if the application is running on a EC2 instance
    at org.springframework.util.Assert.state(Assert.java:392) ~[spring-core-4.3.2.RELEASE.jar:4.3.2.RELEASE]
    at org.springframework.cloud.aws.core.region.Ec2MetadataRegionProvider.getRegion(Ec2MetadataRegionProvider.java:39) ~[spring-cloud-aws-core-1.2.2.RELEASE.jar:1.2.2.RELEASE]
    at org.springframework.cloud.aws.core.config.AmazonWebserviceClientFactoryBean.createInstance(AmazonWebserviceClientFactoryBean.java:98) ~[spring-cloud-aws-core-1.2.2.RELEASE.jar:1.2.2.RELEASE]
    at org.springframework.cloud.aws.core.config.AmazonWebserviceClientFactoryBean.createInstance(AmazonWebserviceClientFactoryBean.java:44) ~[spring-cloud-aws-core-1.2.2.RELEASE.jar:1.2.2.RELEASE]
...
</code></pre>

<p>Is there a clean, working solution for both testing and local development?</p>
