Skip to content

Prerequisites

The documentation applies to:✅ v0.9.0

Before you begin, ensure your environment has been installed these softwares below

Nodejs, NPM & Angular CLI

For NodeJS, we prefer to get LTS version for making sure it works smoothly, you can get by this link below

Nodejs 12.16.0 LTS

For npm, it is included in Nodejs by default. If you want to upgrade npm because Angular, so try this command

npm install -g npm@latest

For Angular and Angular CLI, we prefer to install version 9.1.3

Checkpoint

npm install -g @angular/[email protected]

.NET Core

On Windows OS, you can go this link to download version 3.1

On Ubuntu OS, you need to execute these commands below

wget -q https://packages.microsoft.com/config/ubuntu/19.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb

sudo dpkg -i packages-microsoft-prod.deb

sudo apt-get update

sudo apt-get install apt-transport-https

sudo apt-get update

sudo apt-get install dotnet-sdk-3.1

Optional: Create self-signed certificate

If you have a plan to use LET Portal without Proxy server or debugging on Local, you should create self-signed certificate to run.

``` powershell tab="Windows" dotnet dev-certs https -ep ${USERPROFILE}.aspnet\https\letportal.pfx -p letportal dotnet dev-certs https -ep ${USERPROFILE}.aspnet\https\letportal-cms.pfx -p letportal

``` bash tab="Linux"
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout $HOME/.aspnet/https/letportal.key -out $HOME/.aspnet/https/letportal.crt
sudo openssl pkcs12 -export -out $HOME/.aspnet/https/letportal.pfx -inkey $HOME/.aspnet/https/letportal.key -in $HOME/.aspnet/https/letportal.crt
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout $HOME/.aspnet/https/letportal-cms.key -out $HOME/.aspnet/https/letportal-cms.crt
sudo openssl pkcs12 -export -out $HOME/.aspnet/https/letportal-cms.pfx -inkey $HOME/.aspnet/https/letportal-cms.key -in $HOME/.aspnet/https/letportal-cms.crt

Warning

In CMD, you should use %USERPROFILE%. In Powershell, you should use ${USERPROFILE}.

Docker

If you want to deploy on Docker, you can install latest Docker.

Debug on Docker

We don't have a plan yet for supporting debug on Docker despite Visual Studio Community 2019 supports. A reason is when we started developing, this feature wasn't ready. We still prefer you to debug by Multiple Startup Projects

Database

Choose database type

We should highlight to you this section before you reach further parts. LET Portal can work with these exact databases below:

  • MongoDB 3.6 and later
  • SQL Server 2016 and later
  • PostgreSQL 10 and later
  • MySQL 5.5, 5.6 and 5.7

These databases and versions above are using for our development and test. However, you can try to connect with lower version, we don't ensure our installed driver (such as ADO.NET, MongoDB C# Driver) is working well. For backward compatible, you should check in their driver's documentation. We ONLY ensure to update latest driver.

Ensure MongoDB

LET Portal is supporting many databases but we are struggling to de-couple a MongoDB outside our solution. We are using a MongoDB as a centralized log database following Serilog's configuration. The reasons why we choose MongoDB instead of any SQL database are:

  • Maximum throughput on write
  • Document-based instead of column-based, so it is schemaless
  • Can transfer to ELK later (low priority)