Skip to content

Commit

Permalink
Version 0.33-alpha
Browse files Browse the repository at this point in the history
  • Loading branch information
riclolsen committed May 21, 2024
1 parent ea8605c commit b0c0bb9
Show file tree
Hide file tree
Showing 13 changed files with 98 additions and 21 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ To provide an easy to use, fully-featured, scalable, and portable SCADA/IIoT-I4.
* MongoDB as the real-time core database, persistence layer, config store, SOE historian.
* Event-based realtime async data processing with MongoDB Change Streams.
* Portability and modular interoperability over Linux, Windows, Mac OSX, x86/64, ARM.
* Windows installer available in the [releases section](https://github.com/riclolsen/json-scada/releases/tag/V0.32-alpha).
* Windows installer available in the [releases section](https://github.com/riclolsen/json-scada/releases/tag/V0.33-alpha).
* Unlimited tags, servers, and users.
* Horizontal scalability, from a single computer to big clusters (MongoDB-sharding), Docker containers, VMs, Kubernetes, cloud, or hybrid deployments.
* Modular distributed architecture. Lightweight redundant data acquisition nodes can connect securely over TLS to the database server. E.g. a Raspberry PI can be a data acquisition node.
Expand Down Expand Up @@ -83,7 +83,7 @@ To provide an easy to use, fully-featured, scalable, and portable SCADA/IIoT-I4.
## Documentation

* [Install Guide](https://github.com/riclolsen/json-scada/blob/master/docs/install.md)
* [Windows installer](https://github.com/riclolsen/json-scada/releases/tag/V0.32-alpha)
* [Windows installer](https://github.com/riclolsen/json-scada/releases/tag/V0.33-alpha)
* [Docker Demo](https://github.com/riclolsen/json-scada/blob/master/demo-docker/README.md)
* [Schema Documentation](https://github.com/riclolsen/json-scada/blob/master/docs/schema.md)
* [Config File](https://github.com/riclolsen/json-scada/blob/master/conf/README.md)
Expand Down
4 changes: 2 additions & 2 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ To provide an easy to use, fully-featured, scalable, and portable SCADA/IIoT-I4.
* MongoDB as the real-time core database, persistence layer, config store, SOE historian.
* Event-based realtime async data processing with MongoDB Change Streams.
* Portability and modular interoperability over Linux, Windows, Mac OSX, x86/64, ARM.
* Windows installer available in the [releases section](https://github.com/riclolsen/json-scada/releases/tag/V0.32-alpha).
* Windows installer available in the [releases section](https://github.com/riclolsen/json-scada/releases/tag/V0.33-alpha).
* Unlimited tags, servers, and users.
* Horizontal scalability, from a single computer to big clusters (MongoDB-sharding), Docker containers, VMs, Kubernetes, cloud, or hybrid deployments.
* Modular distributed architecture. Lightweight redundant data acquisition nodes can connect securely over TLS to the database server. E.g. a Raspberry PI can be a data acquisition node.
Expand Down Expand Up @@ -83,7 +83,7 @@ To provide an easy to use, fully-featured, scalable, and portable SCADA/IIoT-I4.
## Documentation

* [Install Guide](docs/install.md)
* [Windows installer](https://github.com/riclolsen/json-scada/releases/tag/V0.32-alpha)
* [Windows installer](https://github.com/riclolsen/json-scada/releases/tag/V0.33-alpha)
* [Docker Demo](demo-docker/README.md)
* [Schema Documentation](docs/schema.md)
* [Config File](conf/README.md)
Expand Down
30 changes: 20 additions & 10 deletions platform-windows/create_services.bat
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ rem nssm set JSON_SCADA_metabase AppEnvironmentExtra MB_JWT_ENABLED="true"
nssm set JSON_SCADA_metabase Start SERVICE_DELAYED_AUTO_START

rem MONGODB
nssm install JSON_SCADA_mongodb "C:\json-scada\platform-windows\mongodb-runtime\bin\mongod.exe" --config "c:\json-scada\platform-windows\mongodb-conf\mongod.cfg"
nssm install JSON_SCADA_mongodb "C:\json-scada\platform-windows\mongodb-runtime\bin\mongod.exe" --config "c:\json-scada\platform-windows\mongodb-conf\mongod.cfg"
nssm set JSON_SCADA_mongodb Start SERVICE_AUTO_START

nssm install JSON_SCADA_calculations "C:\json-scada\bin\calculations.exe" 1 1 2.0 "c:\json-scada\conf\json-scada.json"
Expand All @@ -41,14 +41,14 @@ nssm set JSON_SCADA_calculations Start SERVICE_AUTO_START
REM See log rotation options https://nssm.cc/usage#io

nssm install JSON_SCADA_cs_data_processor "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\cs_data_processor\cs_data_processor.js" 1 1 "c:\json-scada\conf\json-scada.json"
nssm set JSON_SCADA_cs_data_processor AppDirectory "C:\json-scada\src\cs_data_processor"
nssm set JSON_SCADA_cs_data_processor AppDirectory "C:\json-scada\src\cs_data_processor"
nssm set JSON_SCADA_cs_data_processor AppStdout C:\json-scada\log\cs_data_processor.log
nssm set JSON_SCADA_cs_data_processor AppRotateOnline 1
nssm set JSON_SCADA_cs_data_processor AppRotateBytes 10000000
nssm set JSON_SCADA_cs_data_processor Start SERVICE_AUTO_START

nssm install JSON_SCADA_cs_custom_processor "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\cs_custom_processor\cs_custom_processor.js" 1 1 "c:\json-scada\conf\json-scada.json"
nssm set JSON_SCADA_cs_custom_processor AppDirectory "C:\json-scada\src\cs_custom_processor"
nssm set JSON_SCADA_cs_custom_processor AppDirectory "C:\json-scada\src\cs_custom_processor"
nssm set JSON_SCADA_cs_custom_processor AppStdout C:\json-scada\log\cs_custom_processor.log
nssm set JSON_SCADA_cs_custom_processor AppRotateOnline 1
nssm set JSON_SCADA_cs_custom_processor AppRotateBytes 10000000
Expand All @@ -57,7 +57,7 @@ nssm set JSON_SCADA_cs_custom_processor Start SERVICE_AUTO_START

REM CHOOSE ONE: server_realtime (no user control) or server_realtime_auth (token based auth and RBAC)

REM nssm install JSON_SCADA_server_realtime "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\server_realtime\index.js" NOAUTH
REM nssm install JSON_SCADA_server_realtime "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\server_realtime\index.js" NOAUTH
REM nssm set JSON_SCADA_server_realtime AppDirectory "C:\json-scada\src\server_realtime"
REM nssm set JSON_SCADA_server_realtime Start SERVICE_AUTO_START
rem Use environment variables to connect (for reading) to PostgreSQL historian (https://www.postgresql.org/docs/current/libpq-envars.html)
Expand All @@ -74,7 +74,7 @@ set /a rand=%Random%%%62
set buffer=!buffer!!char:~%rand%,1!
if !count! leq !length! goto Loop

nssm install JSON_SCADA_server_realtime_auth "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\server_realtime_auth\index.js"
nssm install JSON_SCADA_server_realtime_auth "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\server_realtime_auth\index.js"
nssm set JSON_SCADA_server_realtime_auth AppDirectory "C:\json-scada\src\server_realtime_auth"
nssm set JSON_SCADA_server_realtime_auth Start SERVICE_AUTO_START
nssm set JSON_SCADA_server_realtime_auth AppEnvironmentExtra JS_JWT_SECRET=%buffer%
Expand All @@ -85,26 +85,36 @@ nssm set JSON_SCADA_server_realtime_auth AppRotateBytes 10000000
rem Use environment variables to connect (for reading) to PostgreSQL historian (https://www.postgresql.org/docs/current/libpq-envars.html)
rem nssm set JSON_SCADA_server_realtime_auth AppEnvironmentExtra PGHOSTADDR=127.0.0.1 PGPORT=5432 PGDATABASE=json_scada PGUSER=json_scada PGPASSWORD=json_scada

nssm install JSON_SCADA_demo_simul "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\demo_simul\index.js"
nssm install JSON_SCADA_demo_simul "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\demo_simul\index.js"
nssm set JSON_SCADA_demo_simul AppDirectory "C:\json-scada\src\demo_simul"
nssm set JSON_SCADA_demo_simul Start SERVICE_DEMAND_START

nssm install JSON_SCADA_alarm_beep "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\alarm_beep\alarm_beep.js"
rem Service to send protocol data updates on mongodb to another JSON-SCADA instance (one-way via UDP)
nssm install JSON_SCADA_mongofw "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\mongofw\index.js"
nssm set JSON_SCADA_mongofw AppDirectory "C:\json-scada\src\mongofw"
nssm set JSON_SCADA_mongofw Start SERVICE_DEMAND_START

rem Service to receive protocol data updates from another JSON-SCADA instance (one-way via UDP)
nssm install JSON_SCADA_mongowr "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\mongowr\index.js"
nssm set JSON_SCADA_mongowr AppDirectory "C:\json-scada\src\mongowr"
nssm set JSON_SCADA_mongowr Start SERVICE_DEMAND_START

nssm install JSON_SCADA_alarm_beep "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\alarm_beep\alarm_beep.js"
nssm set JSON_SCADA_alarm_beep AppDirectory "C:\json-scada\src\alarm_beep"
nssm set JSON_SCADA_alarm_beep_auth AppStdout C:\json-scada\log\alarm_beep.log
nssm set JSON_SCADA_alarm_beep AppRotateOnline 1
nssm set JSON_SCADA_alarm_beep AppRotateBytes 10000000
nssm set JSON_SCADA_alarm_beep Start SERVICE_AUTO_START

rem WARNING! This service has no security access control, use with care.
nssm install JSON_SCADA_config_server_excel "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\config_server_for_excel\index.js"
nssm install JSON_SCADA_config_server_excel "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\config_server_for_excel\index.js"
nssm set JSON_SCADA_config_server_excel AppDirectory "C:\json-scada\src\config_server_for_excel"
nssm set JSON_SCADA_config_server_excel Start SERVICE_DEMAND_START
nssm set JSON_SCADA_config_server_excel AppEnvironmentExtra JS_CSEXCEL_IP_BIND=0.0.0.0 JS_CSEXCEL_HTTP_PORT=10001
rem JS_CSEXCEL_IP_BIND=127.0.0.1 to enable just local access

rem For use with OSHMI HMI Shell
rem nssm install JSON_SCADA_shell_api "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\shell-api\shell-api.js"
rem nssm install JSON_SCADA_shell_api "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\shell-api\shell-api.js"
rem nssm set JSON_SCADA_shell_api AppDirectory "C:\json-scada\src\shell-api"
rem nssm set JSON_SCADA_shell_api Start SERVICE_AUTO_START

Expand Down Expand Up @@ -190,7 +200,7 @@ nssm set JSON_SCADA_plctags AppRotateBytes 10000000
nssm set JSON_SCADA_plctags Start SERVICE_DEMAND_START

REM service for OPC-UA Server
nssm install JSON_SCADA_opcuaserver "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\OPC-UA-Server\index.js" 1 1 "c:\json-scada\conf\json-scada.json"
nssm install JSON_SCADA_opcuaserver "C:\json-scada\platform-windows\nodejs-runtime\node.exe" "C:\json-scada\src\OPC-UA-Server\index.js" 1 1 "c:\json-scada\conf\json-scada.json"
nssm set JSON_SCADA_opcuaserver AppDirectory "C:\json-scada\src\OPC-UA-Server"
nssm set JSON_SCADA_opcuaserver AppStdout C:\json-scada\log\opcuaserver.log
nssm set JSON_SCADA_opcuaserver AppRotateOnline 1
Expand Down
23 changes: 21 additions & 2 deletions platform-windows/json-scada.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ RequestExecutionLevel admin

;--------------------------------

!define VERSION "v.0.32"
!define VERSION_ "0.32.0.0"
!define VERSION "v.0.33"
!define VERSION_ "0.33.0.0"

Function .onInit
System::Call 'keexrnel32::CreateMutexA(i 0, i 0, t "MutexJsonScadaInstall") i .r1 ?e'
Expand Down Expand Up @@ -117,6 +117,9 @@ SetRegView 64
nsExec::Exec 'net stop JSON_SCADA_server_realtime'
nsExec::Exec 'net stop JSON_SCADA_server_realtime_auth'
nsExec::Exec 'net stop JSON_SCADA_config_server_excel'
nsExec::Exec 'net stop JSON_SCADA_demo_simul'
nsExec::Exec 'net stop JSON_SCADA_mongofw'
nsExec::Exec 'net stop JSON_SCADA_mongowr'
nsExec::Exec 'net stop JSON_SCADA_alarm_beeep'
nsExec::Exec 'net stop JSON_SCADA_shell_api'
nsExec::Exec 'net stop JSON_SCADA_process_rtdata'
Expand Down Expand Up @@ -343,6 +346,12 @@ SetRegView 64
SetOutPath $INSTDIR\src\demo_simul
File /a /r "..\src\demo_simul\*.*"

SetOutPath $INSTDIR\src\mongofw
File /a /r "..\src\mongofw\*.*"

SetOutPath $INSTDIR\src\mongowr
File /a /r "..\src\mongowr\*.*"

SetOutPath $INSTDIR\src\grafana_alert2event
File /a /r "..\src\grafana_alert2event\*.*"

Expand Down Expand Up @@ -554,6 +563,16 @@ Section "Uninstall"
ExecWait `"${SC}" delete "JSON_SCADA_demo_simul"`
ClearErrors

ExecWait `"${SC}" stop "JSON_SCADA_mongofw"`
Sleep 50
ExecWait `"${SC}" delete "JSON_SCADA_mongofw"`
ClearErrors

ExecWait `"${SC}" stop "JSON_SCADA_mongowr"`
Sleep 50
ExecWait `"${SC}" delete "JSON_SCADA_mongowr"`
ClearErrors

ExecWait `"${SC}" stop "JSON_SCADA_alarm_beep"`
Sleep 50
ExecWait `"${SC}" delete "JSON_SCADA_alarm_beep"`
Expand Down
17 changes: 17 additions & 0 deletions platform-windows/release_notes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,23 @@ Inkscape+SAGE:

-------------------------------------------------------------------

Notes for version 0.33:

* Default login credentials: username=admin password=jsonscada.
* Metabase credentials: username=json@scada.com password=jsonscada123.
* Added Mongofw and Mongowr processes for data replication over instances.

Requirements and recommendations:

* Windows 10/11 64 bits or Server >=2016, Windows PowerShell. At least 15GB of free space in the "C:" drive.
* Administrative rights. corporate Windows policies may cause problems with the creation of services and the opening of TCP ports.
* Free TCP ports 6688, 6689, 27017, 5432, 80, 8080, 3000, 9000. Other ports may be required for optional services and protocols.
* If the server already has MongoDB, PostgreSQL, Grafana, Nginx or another webserver, please uninstall, disable or watch out for possible conflicts.
* Do not update previously installed JSON-SCADA. Please uninstall previous JSON-SCADA versions before installing a new version.
* If using VirtualBox configure "paravirtualization interface"=KVM, otherwise Nodejs errors may occur.

-------------------------------------------------------------------

Notes for version 0.32:

* Default login credentials: username=admin password=jsonscada.
Expand Down
2 changes: 2 additions & 0 deletions platform-windows/remove_services.bat
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ nssm remove JSON_SCADA_process_hist confirm
nssm remove JSON_SCADA_alarm_beep confirm
nssm remove JSON_SCADA_shell_api confirm
nssm remove JSON_SCADA_demo_simul confirm
nssm remove JSON_SCADA_mongofw confirm
nssm remove JSON_SCADA_mongowr confirm
nssm remove JSON_SCADA_config_server_excel confirm

nssm remove JSON_SCADA_nginx confirm
Expand Down
3 changes: 3 additions & 0 deletions platform-windows/start_services.bat
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ nssm start JSON_SCADA_process_hist
REM nssm start JSON_SCADA_config_server_excel
REM nssm start JSON_SCADA_alarm_beep
REM nssm start JSON_SCADA_shell_api
REM nssm start JSON_SCADA_demo_simul
REM nssm start JSON_SCADA_mongofw
REM nssm start JSON_SCADA_mongowr

REM SELECT PROTOCOLS TO START
nssm start JSON_SCADA_iec104client
Expand Down
4 changes: 4 additions & 0 deletions platform-windows/stop_services.bat
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ nssm stop JSON_SCADA_server_realtime_auth
nssm stop JSON_SCADA_alarm_beep
nssm stop JSON_SCADA_shell_api
nssm stop JSON_SCADA_config_server_excel
nssm stop JSON_SCADA_demo_simul
nssm stop JSON_SCADA_mongofw
nssm stop JSON_SCADA_mongowr

ping -n 2

REM STOP PROTOCOL CLIENTS
Expand Down
2 changes: 1 addition & 1 deletion src/htdocs/i18n/messages_i18n-en_us.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
var Msg =
{
NomeProduto: '{json:scada}',
VersaoProduto: '0.32',
VersaoProduto: '0.33',

NomeVisorTelas: 'Display Viewer',
NomeVisorEventos: 'Events Viewer',
Expand Down
2 changes: 1 addition & 1 deletion src/htdocs/i18n/messages_i18n-pt_br.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
var Msg =
{
NomeProduto: '{json:scada}',
VersaoProduto: '0.32',
VersaoProduto: '0.33',

NomeVisorTelas: 'Visor de Telas',
NomeVisorEventos: 'Visor de Eventos',
Expand Down
2 changes: 1 addition & 1 deletion src/htdocs/i18n/messages_i18n-uk_ua.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
var Msg =
{
NomeProduto: '{json:scada}',
VersaoProduto: '0.32',
VersaoProduto: '0.33',

NomeVisorTelas: 'Перегляд ',
NomeVisorEventos: 'Події',
Expand Down
2 changes: 1 addition & 1 deletion src/htdocs/i18n/messages_i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
var Msg =
{
NomeProduto: '{json:scada}',
VersaoProduto: '0.32',
VersaoProduto: '0.33',

NomeVisorTelas: 'Display Viewer',
NomeVisorEventos: 'Events Viewer',
Expand Down
24 changes: 23 additions & 1 deletion src/mongowr/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit b0c0bb9

Please sign in to comment.