Skip to content

udaaraSH23/Lover-Shop-E-Commerce

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

279 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lover Shop E-Commerce Application

Lover Shop is a full-stack e-commerce web application built using React with Vite for the frontend, Spring Boot for the backend, and MongoDB as the database. This setup leverages Docker to containerize each service, simplifying deployment and development with isolated environments.

Table of Contents


Project Overview

Lover Shop provides a user-friendly platform for users to browse and purchase products. It utilizes Docker for streamlined development and deployment, ensuring that all services are containerized and can be run in any environment that supports Docker.

Tech Stack

  • Frontend: React with Vite (development server and hot-reloading).
  • Backend: Spring Boot (Java) for REST APIs.
  • Database: MongoDB (hosted).
  • Containerization: Docker and Docker Compose.

Prerequisites

Make sure the following tools are installed on your system:


Setup Instructions

1. Clone the Repository

git clone <repository-url>
cd <project-directory>

2. configure-environment-variables

Create a .env file in the root directory of the project to store sensitive information and required configurations.

MongoDB configuration
SPRING_DATA_MONGODB_URI=mongodb+srv://<username>:<password>@cluster0.mongodb.net
-SPRING_DATA_MONGODB_DATABASE=LoverShop

3. Build with Docker

Use Docker Compose to build and start all services in detached mode:

docker-compose up --build -d

Common Docker Commands

Start the Containers

docker-compose up

Build the Containers

docker-compose up --build

Troubleshooting

  • MongoDB Connection Errors:Ensure your MongoDB URI and credentials in the .env file are correct. Verify that MongoDB Atlas allows connections from your IP address.

  • Frontend Not Loading: Make sure the frontend service is running on http://localhost:5173. Check for any network issues or blocked ports.

  • Backend API Not Responding: Ensure the backend service is running and reachable on http://localhost:8080. Check Docker logs for any error messages in the backend container.

About

Lover Shop E-Commerce Application

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •