Git Product home page Git Product logo

raaymax / chat Goto Github PK

View Code? Open in Web Editor NEW
36.0 3.0 2.0 16.84 MB

Quack is a free and open-source chat application designed for private use. Although it doesn't have any unique features, it combines the best features from other communicators. Quack prioritizes privacy and security by allowing users to host their own app, ensuring that they have complete control over their data.

License: MIT License

JavaScript 46.72% HTML 0.17% CSS 2.99% Shell 0.01% TypeScript 49.67% Dockerfile 0.43%
chat communication messaging

chat's Introduction

Tests Release CodeFactor Contributor Covenant License: MIT

Welcome to the Quack - private chatting application.

Quack is a free and open-source chat application designed for private use. With its easy-to-use interface and seamless integration with web browsers, Quack is a Progressive Web Application that can be accessed from any platform that has a web browser, such as Chrome.

Quack is inspired by Slack, but is more affordable for private use. Although it doesn't have any unique features, it combines the best features from other communicators. Quack prioritizes privacy and security by allowing users to host their own app, ensuring that they have complete control over their data.

Configuration

To override default settings chat.config.js file can be created in root directory of the project. File should export folowing object:

type ChatConfig = {
  port?: number // default `PORT` env otherwise `8080`
  sessionSecret?: string // auto generated on first run to `secrets.json` but can be overwritten here
  trustProxy?: bool | string | number // default `uniquelocal` ref: https://expressjs.com/en/guide/behind-proxies.html
  vapid?: { // auto generated on first run to `secrets.json` but can be overwritten here
    publicKey: string
    secretKey: string
  },
  databaseUrl?: string // default `DATABASE_URL` env
  cors?: string[] // by default [ 'https?://localhost(:[0-9]{,4})' ],
  storage?: {
    type: 'memory' | 'gcs' | 'fs' // default `fs` / `memory` in tests
    directory: string // where to save files when type `fs`
    bucket: string // bucket name for `gcs`
  }
  apiUrl?: string // default 'http://localhost:8080' url of api
  appUrl?: string // default 'http://localhost:8081' url for frontend app
};

Environment variables

GOOGLE_APPLICATION_CREDENTIALS [string] - (optional) when gcs storage method is used

Requirements

  • MongoDB
  • (optional) google cloud key for GCS

Files persistence

Currently supporting Google Cloud Storage. To enable it set fileStorage in config file to gcs specify gcsBucket and set GOOGLE_APPLICATION_CREDENTIALS environment variable.

Decisions

Database

We're using a serverless MongoDB instance because of its reliability and cost-effectiveness - we only pay for what we use. The cheapest option available on Mongo Atlas is sufficient for application, as we don't require any internal pub/sub functionality.

Server

It would be nice to have a serverless solution, but for now, the cheapest option is using GCE. I have no idea how to propagate messages to other serverless instances without a hosted pub/sub service. MongoDB, Redis, and Postgres need to be hosted to watch for messages. Perhaps Google Cloud Pub/Sub would be a good option?

Plugins

Chat have plugin system. Example plugin can be found in plugins/example. How to use plugins and plugin hook points TBA.

Local development setup

pnpm i
docker-compose up -d
pnpm run dev

Default credentials

admin / 123

New users can be invited with /invite command which will generate single use link for user registration.

License

MIT License

Copyright (c) 2023 CodeCat

chat's People

Contributors

raaymax avatar github-actions[bot] avatar dependabot[bot] avatar whyplum avatar

Stargazers

 avatar Ramiro Medina avatar  avatar Mateusz Kubaszek avatar  avatar  avatar Chingun Undrakh avatar Myian avatar CJ Thompson avatar vreezy avatar Michał Wakulinski avatar GrosSacASacs avatar Mateusz Harnik avatar Łukasz Krzyżański avatar  avatar  avatar  avatar  avatar Cezary avatar Miedziak avatar Michał Domżalski avatar  avatar Maksymilian Zadka avatar  avatar  avatar Przemysław Królik avatar Jakub Reczko avatar  avatar Patryk Szeliga avatar  avatar filip avatar  avatar kiran avatar Mateusz Witkowski avatar Melisa Russak avatar  avatar

Watchers

 avatar  avatar  avatar

chat's Issues

how to use

Adding a "how to use" guide would be useful.
Nice to have:

  • add screen shots of UI to readme
  • (if possible) create a live demo of app

Can't delete single emoji on mobile

To Reproduce
Steps to reproduce the behavior:

  1. On mobile create emoji
  2. try to backspace it
  3. observe emoji is not deleted

Expected behavior
emoji should be deleted

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.