-
Notifications
You must be signed in to change notification settings - Fork 301
Getting started Development
1. Scada-LTS Installation using standalone installer
Technology | Version | Description |
---|---|---|
Java | 11 | Base programic language |
Gradle | 7.1 | Tool for building the application |
Tomcat | 9.0.75 | Servlet server for application |
MySQL | 8.0.33 | Database server for data persistence |
Node.js | 14.20.1 | JavaScript runtime for New UI |
Git | 2.17.1 | Version control for source code |
1. Scada-LTS Installation using standalone installer ↑↑↑
-
Go to /~https://github.com/SCADA-LTS/linux-installer and select releases tab and then download latest release to desired folder.
-
Go to location of downloaded installer and extract it.
-
Start first script by using terminal and typing
./mysql_start.sh
Script will ask for some basic information to make configuration run correctly. Below is an example of the data that can be entered:
- Port: 3306
- Username: root
- Password: root
- root password: root
After providing the information you should wait for the line confirming the correct operation of the database:
~/linux-installer-1.2.0/mysql/server/bin/mysqld: ready for connections. Version: '8.0.33' socket: '/tmp/mysql.sock' port: 3306 MySQL Community Server - GPL.
-
Start second terminal and run
./tomcat_start.sh
script.Similar to first script you will have to provide some information, example below:
- Enter port: 8080
- Enter username: tcuser
- Enter password: tcuser
- Enter database port: 3306
- Enter database username: root
- Enter database password: root
After that you should be able to access Scada-LTS via web browser by typing in search bar
localhost:8080/Scada-LTS
The base project is written in Java. So to start development a new features to Scada-LTS you need to install Java Development Kit (JDK). Download microsoft-jdk-11.0.18-windows-x64.msi file and run;
When installing Java remember to set Will be installed on local hard drive on Set JAVA_HOME variable.

-
Go to /~https://github.com/SCADA-LTS/windows-installer and select releases tab and then download latest Beta release to desired folder.
NOTE: There always be two versions of standalone installer, beta and non-beta. For development we recommend using Beta version. Non-beta version might be more stable but may not include some important features that are necessery for development.
-
Launch the installer.
NOTE: if blue Windows Defender SmartScreen pop-up appears select "More info" and "Run anyway"
-
Installer will ask for initial Tomcat configuration. Use example data from below:
- Tomcat HTTP Port:
8080
- Username:
root
- Password:
root
NOTE: Installed database is available on port 3308.
- Tomcat HTTP Port:
2. Enviromental variables ↑↑↑
-
You will have to add PATH for Java and Catalina in
~/.bashrc
file using any available text editor e.g.:nano ~/.bashrc
orvim ~/.bashrc
-
On the bottom of this text file add two lines from below:
export CATALINA_HOME="/absolute_path_to_installer/linux-installer-1.2.0/tomcat64/server"
export JAVA_HOME="/absolute_path_to_installer/linux-installer-1.2.0/java/jdk"
-
After all that type in terminal:
source ~/.bashrc
This will reload Enviromental variables.
To add enviromental variables in Windows operating system:
-
(WIN 11) Type in bottom search bar "Edit the system enviroment variables", press Enter and window should pop up.
(WIN 10) On the Windows taskbar, right-click the Windows icon and select System. In the Settings window, under Related Settings, click Advanced system settings. -
Select Enviroment Variables... from the bottom of the window.
NOTE: Do steps below only if you don't see CATALINA_HOME variable in the bottom list.
-
Press New... at the bottom of the window.
For CATALINA_HOME it should look like this:
NOTE: Remember to use your own paths, for Catalina it's Scada-LTS installation location in tomcat folder.
3. Node.js ↑↑↑
-
You can check if you have any nvm or node.js installed on your PC using these commands:
nvm --version node --version
-
You will need
nvm
which is Node Version Manager. You can install it running this command in terminal:curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.2/install.sh | bash
-
You can check if nvm has installed correctly by typing:
nvm --verison
-
When everything went succesfull we can install chosen version of Node.js with command below:
nvm install v14.20.1
-
To make sure that correct version of node is installed type:
node --version
NOTE: If you want to uninstall node or change version of it, you have to use nvm from now on.
To install Node.js on Windows:
-
Download Node.js v14.20.1 intaller from this website: https://nodejs.org/dist/v14.20.1/node-v14.20.1-x64.msi
-
Launch installer, choose install location.
-
When this window appears remember to choose "Will be installed on local hard drive" on Add to PATH.

- Proceed until installation is finished.
4. IntelliJ ↑↑↑
-
Download desired version of IntelliJ here.
-
Put it in freshly made folder and extract it.
-
Go inside extracted folder, then to
bin
folder and run./idea.sh
script. -
Install git with command below:
sudo apt-get install git-all
You can confirm if git setup finished correctly by running
git version
in terminal. -
Intellij is set up and ready to use.
-
Download desired version of IntelliJ here.
-
After installation is completed, on welcome screen select "Create New Project" and select "Get from VCS".
-
Choose repository URL and use Git Version Control. Paste the URL of the Scada-LTS project from below and click "Clone" button.
/~https://github.com/SCADA-LTS/Scada-LTS.git
If there is a privilege dialog, click "Trust this project" button to load the gradle configuration.
Gradle will load the dependencies and prepare project for development. (It may take a while)
- After everything loads, in Project tab, go to gradle > wrapper > gradle-wrapper.properties and change version of your gradle to 7.1.
-
In IntelliJ project in top left corner, go to File > Settings.
-
Type Gradle in search bar.
- In the Gradle JVM dropdown list select correct version of JDK and press OK.
e.g.:
-
In IntelliJ, in Project bar right-click on Scada-LTS and select Open Module Settings.
-
In Project Structure window on left side select Project.
- Select correct version of SDK from dropdown list marked on image above and press OK.
5. DBeaver - MySQL Client ↑↑↑
Download Linux DBeaver Installer, run it and wait for it to finish. To launch it type dbeaver
in console.
Download Windows DBeaver Installer, run it and wait for it to finish. To launch it use desktop icon.
- In top left corner of DBeaver window click on
icon to add "New database connection".
- Select MySQL and press 'Next' button.
- Set port 3308 and click on 'Finish'. If the drivers have not been installed before, the program will suggest downloading and installing, click ok:
6. Docker-compose ↑↑↑
To check if you have any version of docker installed, run command from below in terminal.
dpkg -l | grep -i docker
- Start with commands below to update the
apt
package index:
sudo apt-get update
sudo apt-get install ca-certificates curl gnupg
- Run these commands to add docker’s official GPG key:
sudo install -m 0755 -d /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
sudo chmod a+r /etc/apt/keyrings/docker.gpg
- Use command below to set up repository:
echo \
"deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
"$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
-
Install Docker engine and all necessary docker plugins.
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
-
Install docker-compose itself with command below:
sudo apt install docker-compose
-
Add non-admin user to docker group use command below:
sudo usermod -aG docker user_name
user_name
is the username of user you want to be able to launch docker-compose.
-
Download docker-compose.yml file to desired folder.
-
Go inside docker-compose.yml location using terminal and run:
docker-compose up database
- In second terminal and same location:
-
docker-compose up scadalts
NOTE: You have to wait for
docker-compose up database
to finish, otherwise errors may appear.
To uninstall all files related to docker use these two commands below:
sudo apt-get purge -y `dpkg-query -W -f='${binary:Package}\t' '*docker*'`
sudo apt-get autoremove -y --purge `dpkg-query -W -f='${binary:Package}\t' '*docker*'`
To delete all files that docker created e.g. groups, sockets etc. use commands below:
sudo rm -rf /var/lib/docker /etc/docker
sudo rm /etc/apparmor.d/docker
sudo groupdel docker
sudo rm -rf /var/run/docker.sock
sudo rm /etc/apt/keyrings/docker.gpg
If you deleted everything correctly command below should return nothing.
dpkg -l | grep -i docker
-
Go to https://desktop.docker.com/win/main/amd64/Docker%20Desktop%20Installer.exe and download Docker Desktop Installer
-
Launch installer.
-
Mark "Use WSL 2 instead of Hyper-V (recommended)" checkbox, otherwise you might have problems with virtualization.
NOTE: If you don't see the checkbox and you are having trouble launching Docker, go to Troubleshoot section below.
-
Wait until insallation is finished and restart your PC.
-
Download docker-compose.yml file to desired folder.
-
Right click on the folder where your docker-compose.yml file is and press Open in Windows Terminal and run:
docker-compose up database
- In second terminal and same location:
-
docker-compose up scadalts
NOTE: You have to wait for
docker-compose up database
to finish, otherwise errors may appear.
After setup is finished you should be able to access Scada-LTS via web browser by typing localhost:8080/Scada-LTS
URL in search bar.
NOTE: If you are having problems with virtualization visit this website and follow the instructions.
If your docker doesn't work you can try enabling and disabling certain features. If that doesn't help, follow docker instructions.
- Windows 10 - Enabling features from image below might help with virtualization errors.
If there is "Hyper-V" feature on your list, disable it.
To enter Windows features window type in bottom search bar "Turn Windows features on or off" and press enter.
7. jSerialComm Configuration ↑↑↑
More information about jSerialComm: https://fazecast.github.io/jSerialComm/
However, on linux system configuration is necessary as long as we are not running on root:
sudo usermod -a -G uucp username
sudo usermod -a -G dialout username
sudo usermod -a -G lock username
sudo usermod -a -G tty username
Scada-LTS installer automatically installs jSerialComm.jar to your project. This .jar file will automatically select and load the correct native jSerialComm library for your platform and architecture.
In case of any problems with this library we refer to official sources and their Troubleshoot section.
Archives (Date: 30.06.2023) ↑↑↑
- Current technology stack table
- Tools Installation
- Scada-LTS project initialization
- Integrated Developmnet Environments (IDEs)
- Quick install - Linux Ubuntu 20.04+
Technology | Version | Description |
---|---|---|
Java | 11 | Base programic language |
Gradle | 7.1 | Tool for building the application |
Tomcat | 9.0.41 | Servlet server for application |
MySQL | 5.7 | Database server for data persistence |
Node.js | 14.20.1 | JavaScript runtime for New UI |
Git | 2.17.1 | Version control for source code |
The base project is written in Java. So to start development a new features to Scada-LTS you need to install Java Development Kit (JDK). You can do that easily by downloading the valid version from the jdk.java.net website. Then you only need to extract that file and set-up the PATH variable to /bin directory.
- For windows download dedicated Windowsx64.zip version.
- Extract that file in location where you want to keep your Java binaries
(for example C:\services\java\jdk-11) - Set-up the PATH environment variable to bin directory of your installation location
(for example C:\services\java\jdk-11\bin) - Verify that Java is installed correctly, open your terminal and type
java -version
- For Linux base systems download Linux_x64.tar.gz
- Create a directory
sudo mkdir /opt/java
- Extract archive to that directory
(for example:sudo tar -xzf openjdk-11*.tar.gz -C /opt/java/
) - Set-up the PATH environment variable to bin directory of you installation location
(for examplenano ~/.bashrc
and then add at the bottom of that file this lines and save it)
export JAVA_HOME=/opt/java/jdk-11
export PATH=$JAVA_HOME/bin:$PATH
- Verify that Java is installed correctly, open your terminal and type
java -version
Gradle is a general-purpose build tool that makes taht the build process is very simple. Installation of gradle is well described on their official web page. So follow the tutorial and then verify that gradle is installed:
gradle -v
Support Gradle v6.8.1-v7.1
Tomcat is an servlet web-application server.
-
Download the Tomcat server from their official distribution page
(If you want to download a specific version use that link to dist archive) -
Extract that file to specific location
- Windows: like in our example to
C:\services\tomcat
- Linux: in the same way as before but to
/opt/tomcat
- Windows: like in our example to
-
Set-up the new environment variable with name:
CATALINA_HOME
that is a reference to tomcat main directory.
(That is required to perform Java build operation) -
Import additional Tomcat server libraries:
- Add that file to
/usr/share/tomcat9/lib/
directory. - Add files from that directory to tomcat
/usr/share/tomcat9/lib/
libs.
- Add that file to
-
Setup the Database connection in
$CATALINA_HOME\conf\context.xml
file.
Replace it with that configuration fileFrom version 2.6.10 there's change in context.xml to work with Docker Compose, so after coping this file to Tomcat, change line:
url="jdbc:mysql://database:3306/scadalts"
tourl="jdbc:mysql://localhost:3306/scadalts"
MySQL must be matching the provided version. If not there will be a problem with establishing the connection from the Scada-LTS application.
- Use dedicated installer
- Configure default password to "root" user: "root".
- Create a new database with name: "scadalts".
There is a know bug that on Ubuntu 20.xx there is a problem with installing the MySQL server. It was solved by using the docker image with that server version.
- Install mysql-server package
sudo apt update sudo apt install mysql-server-5.7
- Configure MySQL server with defaulr password to "root" user: "root".
sudo mysql_secure_installation
- Initialize MySQL data directory
- Versions < 5.7.6 -
mysql_install_db
- Versions >= 5.7.6 -
mysqld --initialize
- Versions < 5.7.6 -
- Enable MySQL server
sudo systemctl start mysql
- Create a new database with name: "scadalts".
If there is a problem with MySQL server check the Internet for the solution. This installation process was based on the digitalOcean tutorial so check it for more details.
- Download the Long Term Support (LTS) version of Node.js from official site.
- Extract that file to specific location
- Windows: like in our example to
C:\services\node
- Linux: in the same way as before but to
/opt/node
- Windows: like in our example to
- Add a new entry to
PATH
that is a reference to Node.js main directory.
(/opt/node/node-v15/bin:$PATH) - Verify that Node.js is installed correctly, open your terminal and type
node -v
- Verify that Node Package Manager (npm) was installed with Node.js correctly.
Open your terminal and typenpm -v
Linux has installation of git by default. So you don't need to install it, but on Windows you need to download it from official site. The easiest way to install git is to use the installer.
Find a good place on your local drive where to store your Scada-LTS project. And in that place use Git Tool to download it from the GitHub repository.
git clone /~https://github.com/SCADA-LTS/Scada-LTS.git
Now you should be able to build and run the project using Gradle (support v6.8.1-v7.1). That command will build the Java application from source code and then will try to compile the Frontend apllication with installing all necessary dependencies. Then that two projects will be bundled together into the one Scada-LTS.war
file that will be deployed to the Tomcat server.
gradle buildRunDebugDev
When it will be ready you should be able to access to the application at the following address: localhost:8080/ScadaBR
.
It's up to you to choose the IDE that you want to use. But we recommend to use the JetBrains IntelliJ for the base Java application and VisualStudio Code for the Frontend sub-project. But you can use any other IDE that you want.
1. Install mysql server/client commandline:
2. Install mysql client: (optional)
sudo dpkg -i dbeaver-ce_22.1.4_amd64.deb
3. Install JDK11:
sudo apt update
sudo apt install openjdk-11-jdk
4. Install Apache Tomcat 9:
tar -x -f apache-tomcat-9.0.53.tar.gz
- Set CATALINA_HOME in ~/.bashrc :
vim ~/.bashrc
source ~/.bashrc
- Copy jar lib to CATALINA_HOME/lib from:
/~https://github.com/SCADA-LTS/Scada-LTS/tree/develop/tomcat/lib
/~https://github.com/SCADA-LTS/Scada-LTS/raw/develop/WebContent/WEB-INF/lib/mysql-connector-java-5.1.49.jar
- Copy context.xml file to CATALINA_HOME/conf:
/~https://github.com/SCADA-LTS/Scada-LTS/blob/develop/docker/config/context.xml
5. Install Git:
sudo apt update
sudo apt install git
6. Install npm:
sudo apt update
sudo apt install npm
7. Install and configure Intellij:
tar -x -f ideaIC-2022.2.tar.gz
- run:
./ideaIC-2022.2/bin/idea.sh
- Clone Scada-LTS project;
- Create remote JVM port 8000, module Scada-LTS as remote-debug;
- Build, deploy, and run application (mysql server is running, support Gradle v6.8.1-v7.1):
gradle buildRunDebugDev
8. Open application: Open in browser:
http://localhost:8080/ScadaBR