| z1 | ||
| README.md | ||
Docker Multi-Service Notes Application
Project Overview
This project is a multi-container web application deployed using Docker. It demonstrates how different services can work together using containerization.
The application allows users to:
- Add and delete notes
- Upload files
- View and download uploaded files
Architecture
The application consists of the following services:
Frontend (Nginx) Serves static HTML, CSS, and JavaScript files. Accessible via browser.
Backend (Node.js + Express) Handles API requests and manages notes and file uploads.
MongoDB Stores notes data and uses a persistent Docker volume.
Mongo Express Provides a web interface to view and manage database data.
Technologies Used
- Docker and Docker Compose
- Node.js with Express
- MongoDB (NoSQL database)
- Nginx (web server)
- HTML, CSS, and JavaScript
Service Ports
| Service | Port |
|---|---|
| Frontend | 8080 |
| Backend | 3000 |
| Mongo Express | 8081 |
Persistent Storage
The application uses Docker volumes to preserve data across container restarts:
mongo-datastores database recordsuploads/stores user-uploaded files
Data is retained even after stopping the application.
How to Run
1. Prepare the application
./prepare-app.sh
2. Start the application
./start-app.sh
Once running, open the following in your browser:
- Application:
http://147.232.204.210:8080 - Database UI:
http://147.232.204.210/:8081
3. Stop the application
./stop-app.sh
4. Remove the application
./remove-app.sh
Application Workflow
- The user interacts with the frontend in a browser.
- The frontend sends API requests to the backend.
- The backend processes the requests and communicates with MongoDB.
- MongoDB stores or retrieves the relevant data.
- Mongo Express provides a separate interface to inspect database content directly.
Features
- Create and delete notes
- Upload files
- View and download uploaded files
- Persistent storage via Docker volumes