Code Monkey home page Code Monkey logo

dynamoose-example's Introduction

Description

This repository contains an example on how to use the Dynamoose library (https://dynamoosejs.com/getting_started/Introduction) to communicate with DynamoDB.

Illustration

The diagram below illustrates the different components and how they interact with each other:

Diagram

Setup

  1. Setup AWS & Serverless, make sure you have an .aws directory in your user home folder that contains your credentials and config.

  2. Duplicate the .env.template file based on the stage and set the variable values:

    cp .env.template .env.<stage>
    vim .env.<stage>

    for example:

    cp .env.template .env.personal
    vim .env.personal
  3. Install dependencies in the root folder:

    npm i
  4. Install dependencies for each app in the apps folder:

    cd apps/<app_name>
    npm i

    for example:

    cd apps/comments
    npm i

Deploying the Database to AWS

  1. Run the following command:
    npm run deploy --stage=<stage> --application=db
    for example:
    npm run deploy --stage=personal --application=db

Running a Single Application Locally

  1. Go to the apps folder and run the following command:
    cd apps/<app_name>
    npm run dev --stage=<stage>
    for example:
    cd apps/comments
    npm run dev --stage=personal

Links

dynamoose-example's People

Contributors

mihaelmladenov avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.