Files
raven/docs/8.0/ayanova/docs/ops-install-linux-desktop.md
2022-01-01 00:34:47 +00:00

7.5 KiB

AYANOVA INSTALLATION - LINUX DESKTOP

Please read through all the instructions below before proceeding with installation to be sure everything is available and ready.

The "desktop" installation is appropriate for a single user of AyaNova on a Linux x64 Desktop OS computer accessed with local browser.

Linux distributions

These instructions were compiled and tested on an Ubuntu 21.10 Desktop OS however any Linux x64 distribution should work provided the ASP.NET Core framework can be installed to it.

System requirements

  • OS : Linux x64 desktop operating system supported by ASP.NET Core
  • Internet connection : required to install license and to automatically download the Chromium report rendering engine
  • Disk space: minimum 2GB of free disk space
  • RAM : 1GB (minimum), 2+ GB (recommended)
  • Modern web browser with Javascript enabled

Installation procedure

ASP.NET Core runtime

AyaNova requires the ASP.NET Core runtime version 6.0 or newer. Install the "ASP.NET CORE RUNTIME" (NOT SDK VERSION) using this guide for your specific OS https://docs.microsoft.com/en-us/dotnet/core/install/linux

There are three different versions of .net core listed, be sure you select the "ASP.NET Core Runtime" version.

NOTE: In the example command lines in the linked pages above they are sometimes missing the sudo command, be sure to add it before commands listed there if non root user.

Confirm ASP.NET Core runtime is installed and available before proceeding to the next step:

dotnet --list-runtimes

The AspNetCore runtime should be displayed with version 6 or newer:

Microsoft.AspNetCore.App 6.0.0 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 6.0.0 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

If you do not see this go through the installation steps above again.

PostgreSQL server

AyaNova requires access to a PostgreSQL database server version 12 or newer. If you do not have a PostgreSQL server already available then it must be installed to a location visible to the AyaNova server (same computer or a local computer on the same network).

We recommend not using the version of PostgreSQL provided by your OS package manager as they tend to be out of date.

To install PostgreSQL directly start here https://www.postgresql.org/download/linux/

Set the PostgreSQL password

If you are installing a local copy of PostgreSQL for the first time to use with AyaNova a password will need to be set for secure access. PostgreSQL on linux defaults to no password and must be secured. If you have an existing PostgreSQL server then you can skip this step but will need a PostgreSQL server password in a later step.

Open a PostgreSQL psql console as the postgres user:

sudo -u postgres psql

Set your desired password:

ALTER USER postgres PASSWORD 'YOUR_PASSWORD_HERE';

If successful psql will display "ALTER ROLE" in response and you can close the psql console by typing \q to quit.

Create folders for AyaNova

AyaNova requires two folders to be created, one to hold the AyaNova binary and other server and web application files and one to hold the AyaNova data. AyaNova will need to write to both these locations so be sure you choose locations with appropriate permissions.

From the terminal:

Create the data folder, for desktop linux we recommend your user home folder and AyaNova defaults to '~/.ayanova-data' in it's configuration, however you can use any location that you have write access to.

sudo mkdir ~/.ayanova-data

Create the AyaNova binary files folder. For desktop linux we recommend /usr/bin/ayanova.

sudo mkdir /usr/bin/ayanova

Download the AyaNova binaries archive

https://www.ayanova.com/download/ayanova-linux-x64-desktop.zip

Download the the AyaNova server binary files folder created in the previous step or copy it there from the terminal:

sudo cp ayanova-linux-x64-desktop.zip /usr/bin/ayanova/

Unzip the archive

Unzip the archive into the AyaNova server binary files folder created in the previous step.

sudo unzip ayanova-linux-x64-desktop.zip

Set execute permission

From the terminal in the AyaNova binary files folder:

sudo chmod 777 ./AyaNova

Server configuration

The server must be configured before it will be able to start properly and find the database server.

The AyaNova bin folder has a config.json file which is AyaNova's initial source for configuration settings required for the server to start. It is necessary to edit this file (or provide an alternative source of configuration and specify the password to connect to the PostgreSQL server. For example, if editing the default config.json file:

{
  "AYANOVA_USE_URLS": "http://*:7575",
  "AYANOVA_DB_CONNECTION": "Server=localhost;Username=postgres;Password=YOUR_PASSWORD_HERE;Database=AyaNova;",
  "AYANOVA_DEFAULT_TRANSLATION": "en",
  "AYANOVA_DATA_PATH": "~/.ayanova-data",
  "AYANOVA_LOG_LEVEL": "Info"
}

The AYANOVA_DB_CONNECTION property must be edited and where it has "YOUR_PASSWORD_HERE" substitute the actual PostgreSQL password to be used that was previously set. If the database server is located on a different computer then the Server= connection string property must be set to the address of that computer.

The AYANOVA_USE_URLS property specifies which TCP / IP Port that AyaNova server should listen on for connections from web browsers. The default value is port 7575 which should be free in most cases, however if you need to use an alternate port due to conflict it must be set here. We recommend using the default 7575 to avoid current or future confusion or conflict with other servers that may be installed or present elsewhere on the network.

Edit the config.json file using Nano text editor:

sudo nano config.json

Make changes and save with ctr-x and type y to answer "Save modified buffer?" prompt.

Boot and test AyaNova server

Start the server from the AyaNova bin folder in a terminal windows (ctrl-alt-t)

./AyaNova

You should see an output in the terminal that indicates the AyaNova server version and that it is booting. Any problems found that prevent boot up will be displayed here.

If all is well then the console window will display "BOOT: COMPLETED - SERVER OPEN" as well as some other configuration data:

AyaNova server console running

Login to AyaNova web app

Open your web browser and navigate to the AyaNova server URL. Assuming the default port of 7575 is in use then the URL would be http://localhost:7575.

Starting and stopping AyaNova server

To shut down the AyaNova server cleanly use the AyaNova web app form accessed from Server Operations -> Server State and the menu item Shut down server.
Alternatively you can hard shut down AyaNova using the ctrl-c key combination in the terminal console window where AyaNova is running however this is not recommended.

Getting started and using AyaNova

The next step is to follow the getting started guide for using and administrating AyaNova from a business point of view and also the operations maintenance guide to ensure AyaNova runs smoothly and data is safe and secure.