A messaging web app using Websocket technology
- Any server running a debian-like OS
- The ports
80
and8080
must be open on your network.
These node modules are already included in the project directory:
- mariadb
- uuid
- websocket
For theses steps, we will assume that the git directory has already been cloned into the server.
- Install nodeJS with
apt-get install nodejs
. - Install MariaDB with
apt-get install mariadb-server
thenmysql_secure_installation
. - Execute the sql script found in
/server_resources/sql_scripts/db_creation.sql
. - Add a mariadb user and give him editing permissions on the created database. Here is a nice tutorial: https://tableplus.io/blog/2018/09/mariadb-how-to-create-new-user-and-grant-privileges.html
- Add the db user auth infos in
/server_resources/classes/databaseManager.js
in thedbPool
constant. Put the password in/server_resources/private/credentials.js
. - Configure the websocket url in
/client_resources/scripts/wsManager.js
in theWEBSOCKET_URL
constant. - Configure the
/client_resources
directory path in/server_resources/http_server/fs/filesmanager.js
in theCLIENT_RESOURCES_PATH
constant. - Configure the
files
directory path in/server_resources/http_server/fs/filesmanager.js
in theFILES_DIR_PATH
constant. - To start the website you must start the two servers with
node /server_resources/app_start.js
.
- The app is also fully compatible with Microsoft Windows.