Sha256: 00a0a9eb80b75e63d09cda17b798d64ea94e9e838bcf9920b3de0788a9e62dfb

Contents?: true

Size: 853 Bytes

Versions: 89

Compression:

Stored size: 853 Bytes

Contents

module Aws
  module Plugins

    class STSRegionalEndpoints < Seahorse::Client::Plugin

      option(:sts_regional_endpoints,
        default: 'legacy',
        doc_type: String,
        docstring: <<-DOCS) do |cfg|
Passing in 'regional' to enable regional endpoint for STS for all supported
regions (except 'aws-global'), defaults to 'legacy' mode, using global endpoint
for legacy regions.
      DOCS
        resolve_sts_regional_endpoints(cfg)
      end

      private
                                                                       
      def self.resolve_sts_regional_endpoints(cfg)
        env_mode = ENV['AWS_STS_REGIONAL_ENDPOINTS']
        env_mode = nil if env_mode == ''
        cfg_mode = Aws.shared_config.sts_regional_endpoints(
          profile: cfg.profile)
        env_mode || cfg_mode || 'legacy'
      end

    end

  end
end

Version data entries

89 entries across 89 versions & 1 rubygems

Version Path
aws-sdk-core-2.11.473 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.472 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.471 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.470 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.469 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.463 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.462 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.461 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.460 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.459 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.458 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.457 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.456 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.455 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.454 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.453 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.452 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.451 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.450 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb
aws-sdk-core-2.11.449 lib/aws-sdk-core/plugins/sts_regional_endpoints.rb