nickolashkraus / cloudformation-templates Goto Github PK
View Code? Open in Web Editor NEWA collection of CloudFormation templates
License: MIT License
A collection of CloudFormation templates
License: MIT License
hi
i am using template to deploy lambda funtion
AWSTemplateFormatVersion : '2010-09-09'
Transform: AWS::Serverless-2016-10-31
Description: A sample SAM template for deploying Lambda functions.
Resources:
ApiGatewayApi:
Type: AWS::Serverless::Api
Properties:
Name: Thumbnail
StageName: test
EndpointConfiguration:
Type: REGIONAL
MethodSettings:
- ResourcePath: /
HttpMethod: POST
MetricsEnabled: 'true'
DataTraceEnabled: 'false'
LambdaThumbnail:
Type: AWS::Serverless::Function
Properties:
FunctionName: thumbnail
Handler: com.amazonaws.lambda.thumbnail.Handler::handleRequest
CodeUri: target/thumbnail-1.0.0.jar
Runtime: java8
MemorySize: 512
Timeout: 30
Events:
ApiEvent:
Type: Api
Properties:
Path: /thumbnail
Method: post
RestApiId:
Ref: ApiGatewayApi
but it integrate lambda proxy in api gateway and throw error 502(internal server error) because response format didn't match
.......
i want to deploy non proxy lambda (custom lambda with custom response model) please help me if you can
thank you......
Hi there - thanks for sharing the template as I find it very helpful for my work however I found a minor issue here. ${Lambda.Arn}
doesn't work with !Sub
on this line. I had to use the following code instead:
Fn::Join:
- ""
- - !Sub 'arn:aws:apigateway:${AWS::Region}:lambda:path/2015-03-31/functions/'
- !GetAtt Lambda.Arn
- '/invocations'
Hey Thank you for making this and writing the guides, it has been very helpful.
I followed and deployed the above mentioned code and I keep getting a CloudFront error: MissingAuthenticationTokenException
I've even copied, pasted and deployed your CF code and same issue persists
Hi, I'm trying to create a yaml template using Cloud formation to make an api gateway which integrate to HTTP but couldn't succeed as template throwing errors in yaml. Can you help me with the snippet.
Thanks in advance.
/Sanjeev
Hello Nicholas, I want to say this before the question, I am so amazed by your blog especially CF related articles, thank you so much for this incredible work!.
Question: Based on this template what would be the best way to make api endpoint only accessible with api token.
Also another thing made me confused;
In AWS::ApiGateway::RestApi
resource there is ApiKeySourceType
property set to HEADER
but in AWS::ApiGateway::Method
ApiKeyRequired
property is set to false
. Is it common practice, in case there might be other methods can be protected via api token
?
I am pretty new to CF, so sorry If am asking stupid questions.
Cheers!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.