This project is a minimal clone of the Monkey App, a social media app that allows users to chat with random people. It uses a variety of technologies including ReactJS for the frontend, Redux Toolkit for state management, PeerJS for WebRTC, React useWebSocket, BunJS for the backend, and Docker for containerization and orchestration.
A live demo of the application can be accessed at: https://monkey.misterneo.net
The Monkey App Clone is a project that aims to replicate the functionality of the Monkey App. It allows users to engage in video chats using WebRTC technology. It also allows users to send text messages to each other using WebRTC DataChannel. The app is built using ReactJS for the frontend, Redux Toolkit for state management, PeerJS for WebRTC, React useWebSocket, BunJS for the backend, and Docker for containerization and orchestration.
- ReactJS (Frontend)
- Redux Toolkit (State Management)
- PeerJS (WebRTC)
- React useWebSocket (WebSockets)
- BunJS (Backend)
- Docker (Containerization)
- Docker Compose (Container Orchestration)
Before running the app, ensure that BunJS is installed on your machine. Installation instructions can be found here. If you are unable to install BunJS, you can use the Docker Compose file to run the app with Docker.
- Clone the repository
git clone https://github.com/misterneo/monkey-app-clone.git
cd monkey-app-clone- Go to the
serverdirectory
cd server
- Install the dependencies
bun install- Run the app
bun run index.tsThis will start a WebSocket and HTTP server on port 3000.
Optionally:
You can Specify the port using the
--portflag, e.g.,bun run index.ts --port 5000. Enable debug mode using--debugflag, e.g.,bun run index.ts --debug.
If you decide to change the default port, you will need to update the
VITE_SERVER_PORTvariable in the.env.localfile in theclientdirectory. You can do that by copying the.env.examplefile and renaming it to.env.local. Then, update theVITE_SERVER_PORTvariable to the port you specified.
- Go to the
clientdirectory
cd client- Install the dependencies
bun install- Run the app
bun run devThis will start the app on port 5173. Navigate to http://localhost:5173 to view the app.
- Run the following command at the root of the project to start the app:
docker compose up -d --buildWait for the app to start. This may take a few minutes the first time you run the command.
Navigate to http://localhost:5173 to view the app.
- To stop the app, run the following command:
docker compose downContributions are welcome. Feel free to open a pull request or submit an issue.
This project is licensed under the MIT license. See the LICENSE file for more details.