Skip to content

hamzabenarfa/d-talk-internship

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

65 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ§‘β€πŸ’Ό D-Talk Internship Platform

A full-stack web application built for D-Talk to manage internships, monitor student progress, and facilitate communication between instructors and interns. The platform supports real-time task assignments and comments via WebSockets, features a modern UI with TailwindCSS, and runs on a scalable backend using Node.js, Express, MySQL, and Prisma ORM.

πŸ“¦ Tech Stack

Frontend

  • βš›οΈ React - Modern JavaScript library for building user interfaces
  • πŸ”„ Redux - Predictable state container for JavaScript apps
  • πŸ’¨ TailwindCSS - Utility-first CSS framework for rapid UI development
  • 🌐 WebSocket Client - Real-time communication with the server

Backend

  • πŸš€ Node.js - JavaScript runtime for server-side development
  • 🧩 Express.js - Fast, unopinionated web framework for Node.js
  • πŸ”Œ WebSocket - Native WebSocket for real-time bidirectional communication
  • 🧬 Prisma ORM - Modern database toolkit and ORM
  • 🐬 MySQL - Relational database management system
  • πŸ“§ Nodemailer - Email sending functionality
  • πŸ›‘οΈ Helmet - Security middleware for Express
  • πŸ“ Multer - File upload handling middleware

DevOps & Tools

  • 🐳 Docker Compose - Multi-container Docker application orchestration

πŸš€ Quick Start

Prerequisites

  • Node.js (v16 or higher)
  • Docker & Docker Compose
  • Git

1. Clone the Repository

git clone https://github.com/hamzabenarfa/d-talk-internship.git
cd d-talk-internship

2. Environment Setup

Create .env files in both frontend and backend directories:

Backend .env

# Database Configuration
DATABASE_URL="mysql://dtalk_user:secure_password@localhost:3306/dtalk_db"

# Server Configuration
PORT=4000

# CORS & Client
CLIENT_URL=http://localhost:3000

# JWT Secret (generate a secure one)
JWT_SECRET=your_super_secure_jwt_secret_key

# WebSocket Configuration
SOCKET_PORT=8081

Frontend .env

# API Configuration
WEB_SOCKET_URL=http://localhost:8081

3. Docker Compose Setup

# Start all services (MySQL, Backend, Frontend)
docker-compose up --build

# Or run in detached mode
docker-compose up -d --build

4. Database Migration

# Navigate to backend directory
cd backend

# Run Prisma migrations
npx prisma migrate dev --name init

# Seed the admin account
npx prisma db admin

# Optional: Seed the database
npx prisma db seed

# Open Prisma Studio (Database GUI)
npx prisma studio

✨ Features

🎯 Core Functionality

  • βœ… Internship Listings - Browse and search internship opportunities
  • βœ… Company Profiles - Detailed company information and job postings
  • βœ… User Authentication - Secure login/register for students and companies
  • βœ… Application Management - Track and manage internship applications
  • βœ… Real-time Notifications - Instant updates via WebSockets

🎨 User Experience

  • βœ… Responsive Design - Mobile-first approach with TailwindCSS
  • βœ… Modern UI Components - Clean, professional interface
  • βœ… Advanced Filtering - Search by location, company, skills, etc.
  • βœ… Dashboard Analytics - Statistics and insights for companies

πŸ”§ Technical Features

  • βœ… RESTful API - Well-structured backend API
  • βœ… Database Relations - Optimized MySQL schema with Prisma
  • βœ… File Upload - Resume and company logo upload functionality
  • βœ… Email Integration - Automated notifications and confirmations

πŸ› οΈ Development

Backend Commands

cd backend

# Development server with hot reload
npm run dev

# Production build
npm run build

# Start production server
npm start

# Database operations
npm run db:migrate     # Run migrations
npm run db:seed       # Seed database
npm run db:reset      # Reset database
npm run db:studio     # Open Prisma Studio

Frontend Commands

cd frontend

# Development server
npm run dev

# Production build
npm run build

Docker Commands

# Build and start all services
docker-compose up --build

# Start services in background
docker-compose up -d

# Stop all services
docker-compose down

# View logs
docker-compose logs -f

# Rebuild specific service
docker-compose build backend
docker-compose build frontend

πŸ”’ Security & Best Practices

Authentication & Authorization

  • βœ… JWT Tokens for secure authentication
  • βœ… Password Hashing using bcrypt
  • βœ… Role-based Access Control (Student, Instructor, Admin)
  • βœ… Protected Routes on both frontend and backend

Data Security

  • βœ… Input Validation using yup schemas
  • βœ… SQL Injection Prevention via Prisma ORM
  • βœ… XSS Protection with proper sanitization
  • βœ… CORS Configuration for allowed origins only

Performance & Reliability

  • βœ… Rate Limiting on API endpoints
  • βœ… Database Indexing for optimized queries
  • βœ… Error Handling with proper logging
  • βœ… Request Compression with gzip

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


πŸ‘₯ Team & Contact

Lead Developer: Hamza Benarfa

Project Repository: github.com/hamza-benarfa/dtalk-internships


πŸ™ Acknowledgments

  • D-Talk Team for project vision and requirements
  • Open Source Community for amazing tools and libraries

πŸ“š Additional Resources


⭐ Star this repository if you find it helpful!

Built with ❀️ for connecting talent with opportunities

Made with React Node.js MySQL Docker

About

πŸ§‘β€πŸ’Ό Internship platform for D-Talk to monitor student progress with real-time tasks and comments via WebSockets β€” built with React, Node.js, Prisma, MySQL, and TailwindCSS.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors