Coder Social home page Coder Social logo

marcfeather / app-faye-chat Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fenhanwang/app-faye-chat

0.0 2.0 0.0 880 KB

Skype like chat application using faye and angularJS

CSS 7.06% Ruby 0.57% HTML 5.15% JavaScript 86.79% Batchfile 0.24% Shell 0.19%

app-faye-chat's Introduction

app-faye-chat

Skype like chat application using faye, AngularJS, and the DSP.

##Contents

The only folders to be concerned with are /app and /fayeServer. The rest are for testing and are irrelevant as there are no test yet.

##Setup

Open /app/js/services.js and change the 'Locations' service to use the appropriate names and locations for your DSP, storage service, and faye location.

service('Locations',[function() {
    return {
        DSPLocation: url for your DSP,
        FayeLocation: url for faye server :3334,
        DBServiceName: name of storage service
    }
}]).

The url for faye cannot contain 'http' or 'https' as it will determine it's own protocol. So just set it to '//your faye url'. Faye is currently configured to run on port 3334 however, if you wish to change the port simply open the script located at /fayeServer/server.js and change the port number there.

//Config Stuff
app.set('port', your port number here);

The last configuration setting that needs to be changed is in /app/lib/dreamfactory/dreamfactory.js. Change the DSP location to your dsp.

  var DSPLocation = your DSP location,
      PubSubLocation = "http://localhost:3334",
      AppKey = "chat",
      DSPToken = "";

Note: Don't worry about the PubSubLocation. We don't use that for this application.

##Storage Service

We use MongoDB to store the chat sessions but you don't have to. The DreamFactory REST API will allow you to store the data in any database without changing the code. So fire up the database of your choice. Create a DSP service to interact with that database and set the DBServiceName in /app/js/services.js to your recently created service name.

A few notes

People using the chat program must be registered users of the DSP with access to the service that stores messages.

app-faye-chat's People

Contributors

michael9580 avatar

Watchers

James Cloos avatar  avatar

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.