Skip to content

Instantly share code, notes, and snippets.

@jbasdf
Last active August 23, 2016 22:38
Show Gist options
  • Save jbasdf/f3fef046d9b7041c296dd0c4a7cf7e15 to your computer and use it in GitHub Desktop.
Save jbasdf/f3fef046d9b7041c296dd0c4a7cf7e15 to your computer and use it in GitHub Desktop.
serverless.yml that includes JSON-REF for creating dynamo db tables
service: lti
provider:
name: aws
runtime: nodejs4.3
iamRoleStatements:
- Effect: "Allow"
Action:
- "dynamodb:Scan"
- "dynamodb:Query"
- "dynamodb:DescribeStream"
- "dynamodb:GetRecords"
- "dynamodb:GetShardIterator"
- "dynamodb:ListStreams"
Resource:
Fn::Join:
- ""
- - "arn:aws:dynamodb:::"
stage: dev
region: us-east-1
# you can add packaging information here
#package:
# include:
# - include-me.js
# exclude:
# - exclude-me.js
# artifact: my-service-code.zip
functions:
lti:
handler: handler.lti
events:
- http:
path: "lti"
method: get
# - s3: ${bucket}
# - schedule: rate(10 minutes)
# - sns: greeter-topic
resources:
Resources:
$ref: "./dynamodb.json" // dynamodb.json - https://gist.github.com/jbasdf/2514c49d68338f0d6f3f15a7f97e5b98
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment