Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lucianopaci/nodeshop
Orders and Emails services using AWS SQS & Node
https://github.com/lucianopaci/nodeshop
aws mongo mongoose nodejs sqs typescript
Last synced: 30 days ago
JSON representation
Orders and Emails services using AWS SQS & Node
- Host: GitHub
- URL: https://github.com/lucianopaci/nodeshop
- Owner: LucianoPaci
- Created: 2020-03-16T03:11:55.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-07-18T19:43:28.000Z (over 1 year ago)
- Last Synced: 2024-11-16T10:25:39.192Z (3 months ago)
- Topics: aws, mongo, mongoose, nodejs, sqs, typescript
- Language: TypeScript
- Homepage:
- Size: 2.82 MB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Node Shop
Project built as a monorepo that simulates Orders and Emails from a business or shop.
It allows to create orders via API that are sent to a queue so they can be consumed later to create emails and send them to a dummy inbox.### What is used?
* Typescript
* Express
* AWS SQS
* Mongo
* Mongoose
* React
* Redux Toolkit
* Turborepo
* [Changesets](https://github.com/changesets/changesets) for managing versioning and changelogs
* [GitHub Actions](https://github.com/changesets/action) for fully automated package publishing## Architecture
![architecture](https://i.imgur.com/Co79c0Y.png)
### Setting up the configuration
This project uses `nconf` to handle configuration files in a hierarchical way.
It will merge the configs between your `${environment}.yaml` and `default.yaml`, giving a higher priority to whatever is added in the `${environment}.yaml` file.> It is recommended to create a `local.yaml` inside the `config` folder. This file is ignored and won't be commited to Github.
* You will need to obtain your `AWS CLIENT ID` and `AWS SECRET ID` and add them in the `config/local.yaml`
* *You don't need to add them if you have them configured in your CLI** You will need to create a queue in AWS SQS. [Here is explained how](https://stackabuse.com/message-queueing-in-node-js-with-aws-sqs/). Get the URL and add it to the `config/local.yaml`
* You will need to create an account in [Mailtrap](https://mailtrap.io/) to use an Email Sandbox for tests.
In there, you should get all the SMTP Settings as described below and add them in the `config/local.yaml`![SMTP settings](https://i.imgur.com/aQykyQh.png "SMTP settings")
## How to run it?
First, install all packages:
```bash
pnpm run install
```After you created a`config/local.yaml` file, then run:
```bash
pnpm run local
```**The API will be exposed in the PORT 3000**
## Postman Collection
https://documenter.getpostman.com/view/2992116/UzBnpmNY## FrontEnd App
Project created with https://createapp.dev/webpack/react--babel--chai--cleanwebpackplugin--copywebpackplugin--css--mocha--postcss--react-hot-loader--tailwind-css--typescript----
Based of: AWS-SQS Tutorialhttps://stackabuse.com/message-queueing-in-node-js-with-aws-sqs/