v2.1.12 Upgrade Notes
Configuration changes
Replace docker-compose.yml with new version from release folder.
Update container versions in .env to v2.1.12.
Additions to .env.
These should ideally be placed in each respective group in the .env file.
INGRESS_HTTPS_PORT=443
BINDER_BUILD_DRAFT=false
EXCEL_ADDIN_IMAGE=:v2.1.12
MOPS_MESSAGE_BROKER_IMAGE=:v2.1.12
MOPS_REEL_DETECTOR_IMAGE=:v2.1.12
ENABLED_MOPS_MESSAGE_BROKER_IMAGE=false
ENABLED_MOPS_REEL_DETECTOR_IMAGE=false
ENABLED_EXCEL_ADDIN_IMAGE=false
MOPS_MESSAGE_BROKER_REGISTRY=registry.mopssys.com/mops-4.0/containers/mops-message-broker
MOPS_REEL_DETECTOR_REGISTRY=registry.mopssys.com/mops-4.0/containers/mops-reel-detector
EXCEL_ADDIN_REGISTRY=registry.mopssys.com/mops-4.0/containers/mops-excel-add-in
Add VerifyCertificate field to conf/general/general-config.json:
{
"auth": {
"general": {
"token_uri": "<token_uri>",
"redirect_uri": "<redirect_uri>",
"VerifyCertificate": false
}
}
}
[MD-1290] Update all system components to use/set labels
The changes for label support require database updates so make sure you run the database upgrade scripts as well as seed scripts to populate the database with default settings.
[MD-1189] Make sure entity dependency table supports directorySelector format
Entity dependency tables need to be regenerated for these changes to have any effect. This is done by the database upgrade scripts.
[MD-1181] mops-dir: template config has wrong path for jwks cache folder
Unless already done, update the INSTALLDIR\conf\mops-dir\mops-dir.config file:
For jwks_cache_folder, change the value from “C:\mops\cache” to either “C:\mops\cache” or “C:/mops/cache”.
"security": {
"jwks_cache": true,
"jwks_cache_folder": "C:\mops\cache",
"issuers": {{issuerUrls}}
}
Should be changed to:
"security": {
"jwks_cache": true,
"jwks_cache_folder": "C:/mops/cache",
"issuers": {{issuerUrls}}
}
[MD-1146] Make tag service API with update available in release
To make use of Tag Service API, ensure that the file historianApi.json is copied from
{
"apis": [
...
{
"name": "Historian Access",
"path": "/files/historianApi.json"
}
]
}
[MD-1068] Add status handling to Label component
If you have built components to display values colored by status, you may now make use of the built-in functionality of the Label component. Your current component will keep working using the Label component will be simpler and more maintainable. It will also integrate better with system settings where you can select colors for status presentation.
[MD-1014] Extend Display Components library
These components get installed by the database seed scripts and require that the database schema first have been updated.
[MD-703] fx-stack - Update logging to write to file instead of console
Ensure that the system have the following folders
- logs\mops-dir
- logs\mops-dd
- logs\mops-pqis-core
[MD-235] Upgrade postgres server version in container
If you have upgraded to a version of MOPS 4.0 v2.1.12 and is using the PostgreSQL database container you will have received a database upgrade. The new version of the PostgreSQL server is 17.4 compared to the previous 13.0.
If you start the database container without following the steps below, the container will not start successfully. The status of the database container might be “exited” or “running (unhealthy)”.
Run the following command to verify this is the reason why you got that status: docker logs
mops4.0-db01. You should see something similar to these logs:
FATAL: database files are incompatible with server
The data directory was initialized by PostgreSQL version 13, which is not compatible with this version 17.4
Follow the steps below to upgrade the database to version 17.4:
You can check the old PostgreSQL version and the new one after upgrading by looking in this file:
/mops/data/db/PG_VERSION
- Your current PostgreSQL container version is used when starting these upgrade steps. The .ENV file defines the container version to be started.
- Bring MOPS 4.0 containers down with:
docker-compose down. - Revert database container version to the previous version that worked in the env file.
- Bring the database container up with:
docker-compose up -d db. - Check that it is running and healthy with:
docker-compose ps -a. - Export data with
docker exec mops4.0-db01 pwsh -c "pg_dumpall --file=C:/pgsql/backup/<file name>.sql"where file name could be the current MOPS 4.0 version e.g.v_2_1_5.
This will output a file to a shared directory/mops/backup/db/<file name>.sql. Note that the path in the pg_dumpall command is the path as seen from within the container and the container backup folder is bound to/mops/backup/db/. - Bring database container down with:
docker-compose down - Delete contents of
/mops/data/db. When you run the new version it will write new files at startup. - Update database container version to the new version in the .ENV file.
- Bring the new database container up with
docker-compose up -d db
Make sure that the container is running and healthy withdocker-compose ps -abefore importing data in the next step, this may take longer than usual as it is initializing the database and writing new files to/mops/data/db. - When database container is running and healthy, import data to new database container with:
docker exec mops4.0-db01 pwsh -c "psql --file=C:/pgsql/backup/<file name>.sql". - You can now restart all containers with:
docker-compose down; docker-compose up -d db.
[MD-159] Make it possible to inherit permissions for parent entity
An extra step is required in upgrade of this release (from version prior to v2.1.12). You need to run the following installation actions:
- Follow the normal upgrade instruction (Update database schema, Run the directory database seed data scripts)
- Perform an addtional database backup in case of script failure.
- Locate Permission upgrade script.
- The script is located under
<Release Folder>/dbdef/directory/scripts/changescripts/update-inheritence.sql.
- The script is located under
- Run the script as how a regular upgrade script would from the
dbdef/directory/scriptsfolder.- E.g.
psql --file ./changescripts/update-inheritence.sql postgres://…
- E.g.