Skip to content

rishabh8870/DRIVE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

10 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

DRIVE - File Storage Application

πŸ’Ύ Project Overview

DRIVE is a full-stack file storage application built with Node.js, Express, and EJS. This project provides a secure and efficient way to store and manage files online.

✨ Features

  • πŸ“‚ File upload and download functionality
  • πŸ“‹ File organization and management
  • πŸ”’ Secure file storage
  • πŸ“± Responsive web interface
  • ⚑ Fast and efficient file operations

πŸ› οΈ Tech Stack

  • Backend: Node.js, Express.js
  • Template Engine: EJS
  • Language: JavaScript
  • Architecture: MVC Pattern

πŸ“ Project Structure

DRIVE/
β”œβ”€β”€ config/         # Configuration files
β”œβ”€β”€ models/         # Database models
β”œβ”€β”€ routes/         # Application routes
β”œβ”€β”€ views/          # EJS templates
β”œβ”€β”€ node_modules/   # Dependencies
β”œβ”€β”€ app.js          # Main application file
└── package.json    # Project dependencies

πŸš€ Getting Started

Prerequisites

  • Node.js (v14 or higher)
  • npm or yarn

Installation

  1. Clone the repository
git clone https://github.com/rishabh8870/DRIVE.git
  1. Install dependencies
cd DRIVE
npm install
  1. Start the application
npm start
  1. Open your browser and visit http://localhost:3000

πŸ“ Author

Rishabh - @rishabh8870

πŸ”— Links


πŸ“ Recent Updates (Nov 28, 2025)

v1.1 - Enhanced Documentation

  • Improved README with detailed setup instructions
  • Added comprehensive feature descriptions
  • Better project structure documentation
    • Updated documentation and improved code quality

Future Improvements

  • Advanced file compression support
  • User authentication system
  • Cloud storage integration

⭐️ If you find this project useful, please consider giving it a star!

πŸ”Œ API Endpoints

File Operations

  • GET /files - Retrieve all files
  • POST /upload - Upload a new file
  • GET /download/:id - Download a file
  • DELETE /delete/:id - Delete a file
  • GET /file/:id - Get file details

βš™οΈ Environment Configuration

Create a .env file in the root directory:

PORT=3000
DB_HOST=localhost
DB_USER=root
DB_PASSWORD=your_password
DB_NAME=drive_db
NODE_ENV=development
FILE_UPLOAD_PATH=./uploads

πŸ“š Usage Examples

Uploading a File

const formData = new FormData();
formData.append('file', fileInput.files[0]);

fetch('/upload', {
  method: 'POST',
  body: formData
})
.then(res => res.json())
.then(data => console.log('File uploaded:', data))
.catch(err => console.error('Upload failed:', err));

Downloading a File

const fileId = '123';
window.location.href = `/download/${fileId}`;

🀝 Contributing

Contributions are welcome! Here's how you can help:

  1. Fork the repository
  2. Create a new branch (git checkout -b feature/amazing-feature)
  3. Make your changes and commit (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Code Guidelines

  • Use meaningful variable names
  • Write comments for complex logic
  • Follow MVC pattern structure
  • Test your changes before submitting PR
  • Update README if adding new features

πŸ“„ License

This project is open source and available under the MIT License.

πŸ”§ Troubleshooting

Common Issues

Port Already in Use

If you see "Port 3000 is already in use", try:

# Find the process using port 3000
netstat -ano | findstr :3000
# Kill the process or use a different port
set PORT=3001 && npm start

MongoDB Connection Error

Ensure MongoDB is running:

# Start MongoDB service
net start MongoDB

File Upload Fails

  • Check if the uploads directory exists
  • Verify file size limits in configuration
  • Ensure sufficient disk space

Getting Help

If you encounter any issues:

  1. Check existing issues
  2. Create a new issue with detailed information
  3. Include error messages and system information

Last Updated

Updated on Jan 21, 2026 - Documentation improvements

About

Full-stack file storage application with secure upload/download, built with Node.js, Express, and EJS

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors