Table of Contents
Celestia is a modern real-time chat application built with microservices architecture. It supports 1:1 and group messaging, user profiles, real-time communication via WebSockets and Redis Pub/Sub, and a PostgreSQL-backed storage system. Firebase is used for profile media, and Nginx handles routing and gateway management. Currently under active development.
Follow the instructions below to get started.
-
NodeJS v21+
-
PostgresSQL
-
Redis
-
nginx
-
Firebase Account (Spark Plan)
-
WSL (if developing on Windows)
-
Clone this repository
git clone https://github.com/ArmanKhanTech/Celestia.git
-
Configure nginx by pasting this file at
your-nginx-installation-path/conf
-
Start PostgreSQL and Redis servers.
-
Additional Note: Redis isn't natively supported on Windows. You'll have to run it within WSL instead. Follow this tutorial.
-
Import the PostgreSQL schema by executing the following command in your terminal:
psql -U postgres -h localhost -p 5432 -W -d celestia -f schema.sql
-
Paste your own Firebase configs here or just use mine instead.
-
Execute the following commands from the root dir of this project:
cd Frontend npm run start // Start the NextJS Development Server cd ../Backend/User npm run start // Start User Microservice cd ../Chat npm run start // Start Chat Microservice cd ../Auth npm run start // Start Auth Microservice
-
Finally, start the nginx web server by executing
start nginx
. (Note:cd
intoyour-nginx-installation-path
first in-case you haven't set the ENV for nginx yet.)
- Authentication
- Profile Customization: Name, PFP, etc
- 1:1 Chatting
- M:M Chatting (Groups)
- User Lookup (Search users by their usernames)
- E2EE (Pending)
- Supported Message Format: Text Only
- 15+ Themes
- Websockets for real-time, bi-directional communication.
- Redis Pub/Sub for real-time chatting.
- Firebase Storage for storing PFPs.
- Firebase Authentication for authenticating users and automated session management.
- PostgreSQL is used to store user info and conversations.
- Microservices:
a. Chat
b. Auth
c. User
d. Group (Pending) - Web Server & API Gateway: nginx
- Tables:
a. Users: uid, uname, name, email, date_join, is_active, last_seen, profile_pic_url, status
b. Conversations: cid, participants
c. Messages: mid, cid, message, sender, sent_at, receiver, received_at, status
d. Groups: gid, cid, gname, members, desc, admins, created_at
To be added soon
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Don't forget to give the project a star!
Thanks again!
Distributed under the MIT License. See LICENSE
for more information.
Arman Khan - ak2341776@gmail.com
Project Link - https://github.com/ArmanKhanTech/Celestia