Installation
Prerequisites
The following prerequisites are required in order for Trudesk to run.
- NodeJS 9.10 or later
- MongoDB 3.6 or later on-premise or hosted
(MMAPv1)
- Git
- Mail Server
Trudesk is still in active development and its possible you may run into issues during the install process. If you have issues please fill out a bug report.
Release Notes
Detailed release notes for each version are available on GitHub.
Download
To download the latest version please use master
branch on GitHub.
OSX Install
Please verify you have met all of the prerequisites before running the following commands.
For detailed documentation on installing the prerequisites, please visit the documentation for each above.
The following commands will download and install the latest version.
$ git clone https://www.github.com/polonel/trudesk |
By default the server starts listening for incoming connections on http://0.0.0.0:8118
Linux Install
Please verify you have met all of the prerequisites before running the following commands.
For detailed documentation on installing the prerequisites, please visit the documentation for each above.
The following commands will download and install the latest version.
$ git clone https://www.github.com/polonel/trudesk |
By default the server starts listening for incoming connections on http://0.0.0.0:8118
Ubuntu Install Script
The install script will download all the required packages and prompt if you want to install MongoDB locally.
Note: This script is designed to run on a fresh install of Ubuntu 16.04
Ubuntu 16.04
curl -L -s http://www.trudesk.io/install/install_ubuntu.sh | sudo bash |
Installing Trudesk video showing the install processes with the Ubuntu Install Script.
Windows Install
Please verify you have met all of the prerequisites before running the following commands.
For detailed documentation on installing the prerequisites, please visit the documentation for each above.
The following commands will download and install the latest version.
C:\> git clone https://www.github.com/polonel/trudesk |
Virtual Appliance
The trudesk virtual appliance is no longer maintained. It has been superseded by the Ubuntu Install Script.
Docker Install
Trudesk can run as a docker container as well. The below example shows running a MongoDB
container and linking it to a trudesk container.
The below example assumes you have docker already install
Note: In this example all container storage is located on the host.
In order to run trudesk in a multi-host container cluster, you will require a shared storage. (ex: NFS)
Storage - Create directories on host
$ mkdir -p /data/db |
MongoDB Container
The following command will deploy a mongodb 3.6
docker container with the name mongodb
, which we will use to link to our trudesk
container.$ docker run --name mongodb \
-v /data/db:/data/db \
-v /data/configdb:/data/configdb \
-d mongo:3.6
Trudesk Container
The following command will deploy a trudesk 1.0
docker container. The container will expose a NodePort
to access the container.
Get latest updated image of 1.0
$ docker pull polonel/trudesk:1.0
$ docker run --name trudesk --link mongodb:mongodb \ |
The following environment variables are available
TD_MONGODB_SERVER |
Accessing the trudesk container
Once the containers are running, access the trudesk container via the assigned NodePort
.
The following command will list the two running containers. Notice under the ports column
the NodePort - 32772. This will allow access to the trudesk container via http://{hostip}:32772
$ docker ps |
Systemd startup script
The docker containers will not start on reboot. A startup script can relaunch the containers during startup. The following is an example of a systemd startup script.
MongoDB$ sudo vi /etc/systemd/system/docker-mongodb.service
[Unit]
Description=MongoDb Container
Requires=docker.service
After=docker.service
[Service]
Restart=always
ExecStart=/usr/bin/docker start -a mongodb
ExecStop=/usr/bin/docker stop -t 10 mongodb
[Install]
WantedBy=default.target
Trudesk$ sudo vi /etc/systemd/system/docker-trudesk.service
[Unit]
Description=Trudesk Container
Requires=docker-mongodb.service
After=docker-mongodb.service
[Service]
Restart=always
ExecStart=/usr/bin/docker start -a trudesk
ExecStop=/usr/bin/docker stop -t 2 trudesk
[Install]
WantedBy=default.target
Stop the containers if they are running$ docker stop trudesk mongodb
Reload the systemd service files, start the containers, and enable the services for system startup.$ sudo systemctl daemon-reload
$ sudo systemctl start docker-mongodb
$ sudo systemctl start docker-trudesk
$ sudo systemctl enable docker-mongodb
$ sudo systemctl enable docker-trudesk
Nginx Proxy
I recommend using Nginx to access the trudesk container with a hostname/domain name. Check out jwilder/nginx-proxy for more information.
PM2
Process Manager 2 is a great tool to handle running the Trudesk process.
Install and Configure
npm install pm2 -g
will install the pm2
CLI for handling the process.
Linux & MacOS
$ pm2 start {path/to/trudesk}/app.js --name trudesk \ |
Reverse Proxy - Nginx
Trudesk runs on an internal port of 8118
. In order to access Trudesk on port 80, a reverse proxy is recommended. This allows you to setup SSL/TLS for your domain.
nginx.conf - example
http { |