# Watch Party Application
A web application for synchronized video playback with video calling and chat functionality.
## Prerequisites
Ensure you have the following installed on your system:
- Node.js (v14.x or higher)
- npm (v6.x or higher)
- Git
## Installation
### 1. Clone the Repository
First, clone the repository to your local machine:
```sh
git clone https://github.com/your-repo/watch-party.git
cd watch-party
Next, install the required Node.js dependencies:
npm install
Start the Node.js server:
npm start
If you want to serve the HTML file using http-server
, install it globally:
sudo npm install -g http-server
Then, serve the public
directory:
http-server public -p 80
watch-party/
├── public/
│ ├── index.html
│ ├── styles.css
│ └── app.js
├── package.json
├── server.js
└── README.md
- Video Selection: Allows users to select a video file from their local device.
- Synchronized Playback: Ensures that play, pause, and seek actions are synchronized across all users.
- Real-time Chat: Enables users to chat with each other in real-time.
- Video Calling: Supports video calling between users using WebRTC.
- Simple UI: Provides a simple and intuitive user interface.
- Log in to your AWS Management Console.
- Navigate to the EC2 Dashboard.
- Click on "Launch Instance".
- Choose "Ubuntu Server 20.04 LTS" as the AMI.
- Select an instance type (e.g.,
t2.micro
for free tier eligibility). - Configure the instance details as needed.
- Add storage (the default is usually sufficient).
- Add tags (optional).
- Configure the security group:
- Allow HTTP traffic on port 80.
- Allow WebSocket traffic on port 8080.
- Allow SSH traffic on port 22 (for connecting to the instance).
- Review and launch the instance.
- Download the key pair (
.pem
file) and keep it secure.
Use SSH to connect to your instance:
ssh -i your-key-pair.pem ubuntu@your-instance-public-ip
Update the package list and install Node.js, npm, and Git:
sudo apt update
sudo apt install -y nodejs npm git
Clone your project repository:
git clone https://github.com/your-repo/watch-party.git
cd watch-party
Install the necessary Node.js packages:
npm install
Run the server:
npm start
Install http-server
globally if you haven't done so:
sudo npm install -g http-server
Serve the public
directory:
http-server public -p 80
Open your browser and navigate to http://your-instance-public-ip
to access your watch party application.
Update the WebSocket URL in your public/app.js
file to match your server IP:
const socket = io('http://your-instance-public-ip:8080');
- Authentication: Add user authentication to manage access to the watch party.
- Advanced UI: Design a more advanced and user-friendly UI with custom controls and features.
- Mobile Support: Ensure the application is responsive and works well on mobile devices.
- Multiple Video Sources: Allow users to choose from a library of videos or stream from online sources.
This project is licensed under the MIT License - see the LICENSE file for details.
Note: Replace your-repo
with the actual repository name and your-instance-public-ip
with the public IP address of your EC2 instance. If you plan to add a license, create a LICENSE
file in your project root with the appropriate license text. For the MIT license, you can find the template here.
This detailed `README.md` file provides comprehensive instructions for setting up and deploying the Watch Party application, ensuring that users can follow along easily.