skip aws api check
@@ -120,6 +120,10 @@ func ImageCredsWithAWSAuth(lookup func() ImageCreds, logger log.Logger, config A
"exclude-ids", fmt.Sprintf("%v", config.BlockIDs))
}()
+ if config.Regions != nil {
+ okToUseAWS = true
+ logger.Log("info", "using regions from local config")
+ } else {
// This forces the AWS SDK to load config, so we can get
// the default region if it's there.
sess := session.Must(session.NewSessionWithOptions(session.Options{
@@ -140,7 +144,6 @@ func ImageCredsWithAWSAuth(lookup func() ImageCreds, logger log.Logger, config A
okToUseAWS = true
- if config.Regions == nil {
clusterRegion := *sess.Config.Region
regionSource := "local config"
if clusterRegion == "" {
