Created
November 28, 2018 21:21
-
-
Save adrianhall/88141c6b2dfa1b767c0987d6f97d7433 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
custom: | |
# AWS AppSync GraphQL configuration | |
appSync: | |
name: ${self:custom.api} | |
authenticationType: AWS_IAM | |
logConfig: | |
loggingRoleArn: { Fn::GetAtt: [ AppSyncLoggingServiceRole, Arn ]} | |
level: ALL | |
schema: ./schema.graphql | |
dataSources: | |
- type: AMAZON_DYNAMODB | |
name: DynamoDB | |
config: | |
tableName: { Ref: DynamoDBTable } | |
iamRoleStatements: | |
- Effect: Allow | |
Action: | |
- "dynamodb:PutItem" | |
Resource: | |
- { Fn::GetAtt: [ DynamoDBTable, Arn ]} | |
- { Fn::Join: [ "/", [{ Fn::GetAtt: [ DynamoDBTable, Arn ]}, "*" ]]} | |
- type: AMAZON_ELASTICSEARCH | |
name: ElasticSearch | |
config: | |
endpoint: { Fn::Join: [ "", [ "https://", { Fn::GetAtt: [ ElasticSearchDomain, DomainEndpoint ]} ]]} | |
iamRoleStatements: | |
- Effect: Allow | |
Action: | |
- "es:ESHttpGet" | |
Resource: | |
- { Fn::GetAtt: [ ElasticSearchDomain, DomainArn ]} | |
mappingTemplates: | |
- type: Mutation | |
field: addLocation | |
dataSource: DynamoDB | |
request: Mutation-addLocation-request.vtl | |
response: Mutation-addLocation-response.vtl |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment