Welcome to the Full Stack Sample Todo App! This application allows users to manage their tasks with ease. The project is built with a modern tech stack, including Next.js for the frontend and Node.js, Express, PostgreSQL, and Redis for the backend.
Before you begin, ensure you have the following tools installed on your machine:
To run the App you need to modify sample.env in the root of your project directory with the following content:
# backend
DATABASE_URL=postgresql://<Username>:<Password>@db:5432/todo
REDIS_URL=redis://redis:6379
# db (postgres)
POSTGRES_USER=<Username>
POSTGRES_PASSWORD=<Password>
POSTGRES_DB=todo
git clone -b main https://github.com/sakib3001/sample-fullstack-application.git
cd sample-fullstack-application docker compose up -d --buildTo access the todo app open your browser and type:
http://localhost:8080/ docker compose stop docker compose down- Healthchecks for the
dband theredisis not added to the compose file. - The Image size are reduced to
frontend = 877MBand thebackend = 337MB - In some cases, volume binding is crucial for data persistence. Here, I had used the
./pgdatadirectory for data persistence. Alternatively, Docker volumes could be used, but for replication purposes, I prefervolume binding. For the ease of the project structure here I am usingpgdatadocker volume right now.