https://github.com/mmurygin/node-chat
Simple node chat with socket.io and redis for broadcasting messages
https://github.com/mmurygin/node-chat
docker docker-compose nodejs socket-io
Last synced: 2 months ago
JSON representation
Simple node chat with socket.io and redis for broadcasting messages
- Host: GitHub
- URL: https://github.com/mmurygin/node-chat
- Owner: mmurygin
- Created: 2017-10-18T09:53:44.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-11-08T15:20:24.000Z (over 8 years ago)
- Last Synced: 2025-04-21T12:57:20.610Z (about 1 year ago)
- Topics: docker, docker-compose, nodejs, socket-io
- Language: JavaScript
- Homepage:
- Size: 88.9 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Socket.IO Chat
A simple chat demo for socket.io
## Getting Started
1. Install `nodejs` >=8
1. Install `redis`
1. Install node modules
```bash
npm install
```
1. Run app
```bash
REDIS_HOST=localhost REDIS_PORT=6379 node index.js
```
## Dockerized version
1. Install docker
```bash
sudo curl -sSL https://get.docker.com/ | sh && sudo gpasswd -a ${USER} docker
```
* Logout and login
1. [Install docker-compose](https://github.com/docker/compose/releases)
1. Run app
* production
```bash
docker-compose -f docker-compose.yml -f docker-compose.prod.yml up -d
```
* dev
```bash
docker-compose up
```
## Features
- Multiple users can join a chat room by each entering a unique username
on website load.
- Users can type chat messages to the chat room.
- A notification is sent to all users when a user joins or leaves
the chatroom.