Created
January 19, 2021 12:44
-
-
Save rockey5520/a654124bb6b891ce329470f1c0d63474 to your computer and use it in GitHub Desktop.
template.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AWSTemplateFormatVersion: '2010-09-09' | |
Transform: AWS::Serverless-2016-10-31 | |
Parameters: | |
StageName: | |
Type: String | |
Default: Prod | |
Description: XXX | |
Globals: | |
Function: | |
Timeout: 180 | |
HttpApi: | |
Auth: | |
Authorizers: | |
MyOauthAuthorizer: | |
IdentitySource: $request.header.Authorization | |
JwtConfiguration: | |
audience: | |
- https://awsgateway | |
issuer: "https://xxx.xx.com/" | |
DefaultAuthorizer: MyOauthAuthorizer | |
Resources: | |
API: | |
Type: AWS::Serverless::HttpApi | |
Properties: | |
StageName: !Ref StageName | |
XFunction: | |
Type: AWS::Serverless::Function | |
Properties: | |
Handler: xxx.StreamLambdaHandler::handleRequest | |
Runtime: java11 | |
CodeUri: CoreApi | |
MemorySize: 2048 | |
Role: arn:aws:iam::XXXX:role/ZZZZZ | |
Environment: # More info about Env Vars: https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#environment-object | |
Variables: | |
PARAM1: VALUE | |
Events: | |
HttpApiEvent: | |
Type: HttpApi | |
Properties: | |
TimeoutInMillis: 20000 | |
PayloadFormatVersion: '1.0' | |
Outputs: | |
XFunctionApi: | |
Description: URL for application | |
Value: !Sub 'https://${ServerlessHttpApi}.execute-api.${AWS::Region}.amazonaws.com' | |
Export: | |
Name: XFunctionApi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment