Easily provision AWS DynamoDB tables using Serverless Components.
$ npm install -g serverless
Just create a serverless.yml
file
$ touch serverless.yml
$ touch .env # your AWS api keys
# .env
AWS_ACCESS_KEY_ID=XXX
AWS_SECRET_ACCESS_KEY=XXX
# serverless.yml
myTable:
component: "@serverless/aws-dynamodb"
inputs:
attributeDefinitions:
- AttributeName: id
AttributeType: S
keySchema:
- AttributeName: id
KeyType: HASH
region: us-east-1
$ serverless
Checkout the Serverless Components repo for more information.