The IIChE Student Chapter, BIT Mesra is a premier student organization dedicated to promoting innovation, technical excellence, and professional growth in Chemical Engineering. This repository contains the full source code for the official digital platform of the chapter, featuring a dynamic frontend integrated with a robust FastAPI backend.
The platform handles chapter initiatives, technical events (such as Coalescence), workshops, alumni interactions, executive board profiles, secure user authentication, real-time event registration, and an admin management dashboard.
- Modern & Responsive UI: Designed with Tailwind CSS v4 and smooth GSAP/Lenis scroll animations.
- Authentication & Security: Email/password authentication, Google OAuth 2.0, OTP-based password reset, session cookies (HttpOnly, SameSite), and CSRF protection.
- Dynamic Event Registrations: Authenticated user event registration flow with instant feedback and registration status tracking.
- Admin Dashboard: Comprehensive admin panel (
/pages/admin.html) to create/edit events, view live registration counts, manage registrations, and export attendee data to CSV. - Cloudinary Media Delivery: High-performance image hosting for chapter galleries and team photos.
- RESTful API: OpenAPI (Swagger) compliant FastAPI backend built with SQLAlchemy 2.0 async ORM and Alembic database migrations.
| Component | Technology |
|---|---|
| Markup & Styling | HTML5, CSS3, Tailwind CSS v4 (@tailwindcss/cli) |
| Interactivity & Animations | JavaScript (ES6+), GSAP, Lenis Smooth Scroll |
| API Communication | Custom Client SDK (auth-client.js, events-client.js) |
| Component | Technology |
|---|---|
| Framework | Python 3.12+, FastAPI, Uvicorn (ASGI) |
| Database & ORM | PostgreSQL / SQLite, SQLAlchemy 2.0 (Async), Alembic |
| Caching & Rate Limiting | Redis |
| Containerization | Docker, Docker Compose |
| Image Hosting | Cloudinary CDN |
iiche/
βββ index.html # Main landing page
βββ auth-client.js # Frontend Auth & API Client SDK
βββ events-client.js # Dynamic Events & Registration SDK
βββ input.css # Tailwind CSS source file
βββ output.css # Compiled Tailwind CSS output
βββ package.json # Node.js dependencies (Tailwind CLI)
βββ assests/ # Logos, brand assets, images
βββ pages/ # Website pages
β βββ login.html # Login & Account Signup
β βββ forgot-password.html # Request OTP
β βββ verify-otp.html # OTP verification
β βββ reset-password.html # Set new password
β βββ events.html # Events portal
β βββ admin.html # Admin management dashboard
β βββ departments.html # Departmental structure
β βββ committee.html # Team & Committee details
β βββ more.html # Additional resources
βββ events/ # Event specific showcase pages
β βββ coalescnece.26.html
β βββ coalescnece.25.html
β βββ workshop.html
β βββ talks.html
β βββ otherevents.html
βββ committee/ # Executive board & vision
βββ backend/ # FastAPI Backend Application
βββ app/
β βββ main.py # Application entry point
β βββ api/v1/ # API Route Handlers (Auth, Events, Admin, Users)
β βββ core/ # Config, Security, DB session, Dependencies
β βββ models/ # SQLAlchemy ORM Models
β βββ schemas/ # Pydantic Request/Response validation
β βββ services/ # Business Logic Layer
βββ alembic/ # Database Migrations
βββ docker-compose.yml # Docker Compose setup (FastAPI + Postgres + Redis)
βββ Dockerfile # Production container spec
βββ make_admin.py # CLI script to grant admin privileges
βββ requirements.txt # Python dependencies
βββ .env.example # Environment variables template
Before running the website locally, ensure you have the following installed on your machine:
- Node.js:
v18.0.0or higher (includesnpm) - Download Node.js - Python:
v3.12or higher - Download Python - Docker & Docker Compose (Recommended for Backend) - Download Docker Desktop
- (Optional) Git: For repository management.
Follow these step-by-step instructions to get both the Frontend and Backend running on your local machine.
git clone https://github.com/raghavagarwal-debug/iiche-final-repo.git
cd iiche-final-repo-
Install Node Dependencies: Install Tailwind CSS CLI and related dependencies from the root directory:
npm install
-
Compile / Watch Tailwind CSS: Run the Tailwind CLI watcher to automatically compile
input.cssintooutput.csswhen styles change:npx @tailwindcss/cli -i ./input.css -o ./output.css --watch
(Keep this terminal running or run once without
--watchto generateoutput.css). -
Serve the Static Frontend: Launch a local HTTP server from the repository root directory. You can use any of the following options:
-
Option A: VS Code Live Server extension Right-click
index.htmlin VS Code and select "Open with Live Server" (default port5500). -
Option B: Node
serveCLInpx serve -l 5500 . -
Option C: Python Built-in HTTP Server
python -m http.server 5500
The frontend interface will be available at:
http://localhost:5500 -
You can start the backend using Docker Compose (Quickest) or via a Local Python Virtual Environment.
-
Navigate to the backend directory:
cd backend -
Set up Environment Variables: Copy
.env.exampleto create your local.envfile:cp .env.example .env
(Note: On Windows PowerShell, use
copy .env.example .env) -
Start all backend services (FastAPI + PostgreSQL + Redis):
docker-compose up -d --build
-
Run Database Migrations: Apply Alembic migrations to create the required tables in PostgreSQL:
docker-compose exec api alembic upgrade head
If you prefer to run Python directly without Docker containers:
-
Navigate to the backend directory:
cd backend -
Create and Activate a Python Virtual Environment:
- On Windows (PowerShell):
python -m venv venv .\venv\Scripts\activate - On macOS / Linux:
python3 -m venv venv source venv/bin/activate
- On Windows (PowerShell):
-
Install Dependencies:
pip install -r requirements.txt
-
Configure Environment Variables: Create a
.envfile from.env.example:cp .env.example .env
If using SQLite locally instead of PostgreSQL, set
DATABASE_URL=sqlite+aiosqlite:///./iiche_dev.dbin.env. -
Apply Database Migrations:
alembic upgrade head
-
Start the FastAPI Uvicorn Server:
uvicorn app.main:app --reload --host 127.0.0.1 --port 8000
The API server will start at:
http://localhost:8000
To access the Admin Dashboard (/pages/admin.html) and manage events/registrations:
- Open
http://localhost:5500/pages/login.htmlin your browser and register a new user account (or use an existing account). - Open a terminal in the
backend/directory (with virtual environment active or inside Docker container). - Run the
make_admin.pyCLI script with your registered email (and optionally specify a new password):Example:python make_admin.py your_email@example.com [new_password]
python make_admin.py satyamkumar29848@gmail.com admin123
- Log in on the website with your email and password. You can now access
http://localhost:5500/pages/admin.htmlwith full administrative privileges!
| Resource | Service / URL |
|---|---|
| Frontend Homepage | http://localhost:5500 |
| Login & Register | http://localhost:5500/pages/login.html |
| Admin Dashboard | http://localhost:5500/pages/admin.html |
| Events Portal | http://localhost:5500/pages/events.html |
| Backend API Base | http://localhost:8000/api/v1 |
| Swagger Interactive API Docs | http://localhost:8000/docs |
| ReDoc API Documentation | http://localhost:8000/redoc |
| Backend Health Check | http://localhost:8000/health |
- Interactive API Testing: Access
http://localhost:8000/docsto test authentication, user profiles, event management, and registration endpoints directly from your browser. - Automated Tests: Run unit and integration tests for the backend:
cd backend pytest
- Password Hashing: Uses Argon2id algorithm for secure password hashing.
- Session Tokens: HttpOnly, Secure, SameSite cookies prevent XSS and session hijacking.
- CSRF Protection: Token-based validation on all state-changing endpoints.
- Rate Limiting: Redis-backed sliding window rate limits on Auth endpoints.
- Environment Isolation: Sensitive secrets (JWT/Session keys, DB credentials) are stored exclusively in
.envand never committed to Git.
|
Full Stack Developer |
Full Stack Developer |
This project is licensed under the MIT License. See the LICENSE file for details.
