Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/naresh-chandanbatve/email-manager

an nextjs application which fetches all your emails and classify them in different categories
https://github.com/naresh-chandanbatve/email-manager

aws fullstack-development gmail-api googleapi googleauth k8s kubernetes nextauth nextjs terraform

Last synced: 3 days ago
JSON representation

an nextjs application which fetches all your emails and classify them in different categories

Awesome Lists containing this project

README

        

logo

Email Manager




An awsome website to mannage all your emails





contributors


last update


forks


stars


open issues


license




View Demo
·
Documentation
·
Report Bug
·
Request Feature



# :notebook_with_decorative_cover: Table of Contents

- [:notebook\_with\_decorative\_cover: Table of Contents](#notebook_with_decorative_cover-table-of-contents)
- [:star2: About the Project](#star2-about-the-project)
- [:camera: Screenshots](#camera-screenshots)
- [:space\_invader: Tech Stack](#space_invader-tech-stack)
- [:dart: Features](#dart-features)
- [:key: Environment Variables](#key-environment-variables)
- [:toolbox: Installation](#toolbox-installation)
- [:running: Run Locally](#running-run-locally)
- [:whale: Run the Docker Image](#whale-run-the-docker-image)
- [:page\_with\_curl: Note:](#page_with_curl-note)
- [:hammer\_and\_wrench: Recreate the Infrastructure on AWS using Terraform](#hammer_and_wrench-recreate-the-infrastructure-on-aws-using-terraform)
- [AWS Resources that will be created:](#aws-resources-that-will-be-created)
- [:wave: Contributing](#wave-contributing)
- [:scroll: Code of Conduct](#scroll-code-of-conduct)
- [:warning: License](#warning-license)
- [:handshake: Contact](#handshake-contact)

## :star2: About the Project

### :camera: Screenshots


screenshot

### :space_invader: Tech Stack

Client

Server

DevOps

### :dart: Features

- Secure google sign in with NextAuth
- Fetching all your emails
- Classifying emails in different catagories (pending)

### :key: Environment Variables

To run this project, you will need to add the following environment variables to your .env file

`GOOGLE_CLIENT_ID`

`GOOGLE_CLIENT_SECRET`

`NEXTAUTH_SECRET`

`NEXTAUTH_URL`

`REDIRECT_URI`

`REFRESH_TOKEN`

`NEXT_PUBLIC_APP_DOMAIN`

## :toolbox: Installation

### :running: Run Locally

Clone the project

```bash
git clone https://github.com/Naresh-chandanbatve/email-manager.git
```

Go to the project directory

```bash
cd email-manager
```

Install dependencies

```bash
npm install
```

Start the server

```bash
npm run dev
```

### :whale: Run the Docker Image

You can also run the Docker Image to get started easily.
get the Docker Image by running the following command

```bash
docker pull nareshchandanbatve/email-manager:latest
```

Run the docker image by running the following command

```bash
docker run -p 3000:3000 --env-file ./.env nareshchandanbatve/email-manager:latest
```

#### :page_with_curl: Note:
you must have the .env file with all the environment variables listed above

## :hammer_and_wrench: Recreate the Infrastructure on AWS using Terraform

prerequisites:
- you must have the aws IAM account with required permissions
- you must have Terraform installed on your machine

All the Terraform code is available in /terraform directory so go to /terraform directory

Add all the environment variables listed above in the variables.tf file as shown in the varaibles.example.tf file

Then run the following command to intialize terraform

```bash
terraform init
```

Then run the following command it may prompt errors, fix them if any.

```bash
terraform plan
```

Then run and type 'yes' when prompted.

```bash
terraform apply
```

Now you have your infrastructure ready with docker image of this application running on the ec2 server.

#### AWS Resources that will be created:

- EC2 instance
- Custom VPC
- Security Group with allowing all ingress and egress port (warning: It can be security vulnerability, I am allowing all ports for development only allow only ports that are needed for production)
- Subnet
- Internet Gateway
- Routing Table

## :wave: Contributing



Contributions are always welcome!

See `CONRIBUTING.md` for ways to get started.

### :scroll: Code of Conduct

Please read the [Code of Conduct](https://github.com/Naresh-chandanbatve/email-manager/blob/master/CODE_OF_CONDUCT.md)

## :warning: License

Distributed under the MIT License. See LICENSE.txt for more information.

## :handshake: Contact

Naresh Chandanbatve - [@Nareshchandanb1](https://twitter.com/Nareshchandanb1) - [email protected]

Project Link: [https://github.com/Naresh-chandanbatve/email-manager](https://github.com/Naresh-chandanbatve/email-manager)