Sha256: ceb5229491578dc5d0ac769895732f14879d18a311a3fb5b221c07be6891f7d6
Contents?: true
Size: 756 Bytes
Versions: 66
Compression:
Stored size: 756 Bytes
Contents
class Jets::Resource::ChildStack::ApiResource # Find the ApiResource Page that contains the AWS::ApiGateway::Resource # Returns: logical id of ApiResource Page class Page def self.logical_id(parameter) expression = "#{Jets::Naming.template_path_prefix}-api-resources-*" # IE: path: #{Jets.build_root}/templates/demo-dev-2-api-resources-1.yml" template_paths = Dir.glob(expression).sort.to_a found_template = template_paths.detect do |path| next unless File.file?(path) template = Jets::Cfn::BuiltTemplate.get(path) template['Outputs'].keys.include?(parameter) end md = found_template.match(/-(api-resources-\d+)/) md[1].underscore.camelize # IE: ApiResources1 end end end
Version data entries
66 entries across 66 versions & 2 rubygems