FAXES Documentation > FaxCAD > FaxCAD 2.0 Installation

FaxCAD 2.0 Installation

FAXES

This topic goes through the FaxCAD v2 installation. All packages (Standard, Plus, and Elite) have the same install process and use this guide to install the product.


Note:
FaxCAD is a purchased item and can be bought via the FAXES Website.


Step 1 - Setting Up

To be able to run FaxCAD 2.0 you will need a web-server. If you already have one great! This guide will use Linux as the operating system, via a console. We recommend using Ubuntu 18.04 LTS or higher.

Note: This guide may link to other guides or documentation that is external.

FaxCAD 2.0 Requirements:

  • (Web-)Server to host the site.

  • Nginx, Apache or similar web-server software.

  • PHP 7.0+ installed.

  • MySQL Server

If you don't have any of the above, it's okay, that's also in the guide!

If you don't have a server to host FaxCAD 2.0 on. We highly recommend Linode. See our referral link here. Anything from their $5 plan and up should work fine for a start. For the operating system we suggest choosing is Ubuntu 18.04 LTS or higher. Seeming we are using Ubuntu you can use a web shell or download the Ubuntu console from the Microsoft Store.

Once you have a server to build from continue, make sure you're able to login to the server with sudo access (admin access, you should have this by default with your root user).

Step 2 - Installing Nginx, PHP & MySQL

These are super vital to running FaxCAD as FaxCAD 2.0 will not run without these! We highly recommend this guide by Digital Ocean to install LEMP (Linux, Nginx (Engine-X), MySQL, PHP).

Seeming FaxCAD stores user data and information we also suggest using SSL certificates to help protect this. Take a look at this Digital Ocean Guide on How To Secure Nginx with Let's Encrypt.

Now you should be able to see the below picture with the padlock icon to the left of the URL.

IMG

Step 3 - Installing FaxCAD 2.0 Database

If you either have a web-server, or followed the above linked guides you can continue with installing the FaxCAD 2.0 Database.

Extract the installme.sql file and place into the /root folder of your server and open and login to your MySQL terminal via SSH. Try use this command to login; mysql -u root -p If you don't have a root password just press enter.

You will need to create the database itself. To do this run the below code in your SQL terminal. For the purposes of this guide the database name will be myCADDatabase but you can change that to whatever you like.

CREATE DATABASE myCADDatabase CHARACTER SET utf8;

This creates the database myCADDatabase with UTF8 character format.

source installme.sql;

This executes the installme.sql that we put into our /root folder before.

Now your database should be installed and imported. Double check this by doing use myCADDatabase and then SHOW TABLES;, this should display something like the below image.

IMG

Now we have the database installed we can move back to the web-server side and install our PHP files.

Step 4 - Installing FaxCAD 2.0 Website Files

We recommend using a SFTP like FileZilla or WinSCP for this as the command line can be annoying. Extract the files from your CAD Web Files - Step 4 folder from your .rar file into the web directory of your server. This will be the directory you set up in step 2. By default it will be under /var/www. Once navigated move all the files into this directory.

NOTE: Some systems require permissions to upload files to directories. We suggest running the below commands in a terminal replacing the directory to represent your CAD.

sudo chown -R www-data:www-data /var/www/yourCAD
sudo chown -R www-data:www-data /var/www/yourCAD/assets
sudo chown -R www-data:www-data /var/www/yourCAD/assets/civimages

Step 5 - Setting Up Discord OAuth2

To set up Discord OAuth2 head to the Discord developer portal and create an application for your CAD. Once you have created an application for your CAD go to the OAuth2 tab on the left side and add a redirect and write https://mydomain.com. Make sure there is no trailing / this should be the same as your link to your CAD. So make sure to replicate that.

Step 6 - Configuring FaxCAD 2.0

Now we have installed the files for FaxCAD 2.0 we can configure it to make it look like it's meant too. Your config file will look like the below code.

<?php

// MYSQL Database Details //
$host = "localhost";
$username = "root";
$password = "";
$dbName = "myCADDatabase";

// Installation
$installLocation = "/var/www/myCAD"; // Make sure there's no trailing '/'


// Discord OAuth2 Details //
$discordClientId = "DiscordClientID";
$discordClientToken = "DiscordToken";

// Owner Tools //
$ownerId = "YourDiscordID";


// Developer Tools //
$debugMode = false;
?>

Edit the config.php file and fill in all the details and make sure it replicates what we have created above. Once you have completed this, go to your CAD and test it out - you should be all good to go!