Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Upgrade to postgreSQL and midPoint 4.3.2-SNAPSHOT
Slavek Licehammer committed Jun 22, 2021

Unverified

No user is associated with the committer email.
1 parent 4149610 commit be3b3c8
Showing 18 changed files with 123 additions and 66 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
@@ -64,12 +64,12 @@ RUN echo 'Extracting midPoint archive...' \

# Repository parameters

ENV REPO_DATABASE_TYPE mariadb
ENV REPO_DATABASE_TYPE postgresql
ENV REPO_JDBC_URL default
ENV REPO_HOST midpoint_data
ENV REPO_PORT default
ENV REPO_DATABASE registry
ENV REPO_USER registry_user
ENV REPO_DATABASE midpoint
ENV REPO_USER midpoint
ENV REPO_PASSWORD_FILE /run/secrets/mp_database_password.txt
ENV REPO_MISSING_SCHEMA_ACTION create
ENV REPO_UPGRADEABLE_SCHEMA_ACTION stop
6 changes: 3 additions & 3 deletions demo/grouper/.env
@@ -1,10 +1,10 @@
ENV=demo
REPO_DATABASE_TYPE=mariadb
REPO_DATABASE_TYPE=postgresql
REPO_JDBC_URL=default
REPO_HOST=midpoint_data
REPO_PORT=default
REPO_DATABASE=registry
REPO_USER=registry_user
REPO_DATABASE=midpoint
REPO_USER=midpoint
REPO_MISSING_SCHEMA_ACTION=create
REPO_UPGRADEABLE_SCHEMA_ACTION=stop
MP_MEM_MAX=2048m
@@ -1 +1 @@
WJzesbe3poNZ91qIbmR7
WJzesbe3poNZ91qIbmR7
@@ -1 +1 @@
changeit
changeit
19 changes: 10 additions & 9 deletions demo/grouper/docker-compose.yml
@@ -173,18 +173,19 @@ services:
- CREATE_NEW_DATABASE=if_needed

midpoint_data:
image: tier/mariadb:mariadb10
image: postgres:11
environment:
- POSTGRES_PASSWORD_FILE=/run/secrets/mp_database_password.txt
- POSTGRES_USER=midpoint
- POSTGRES_INITDB_ARGS=--lc-collate=en_US.utf8 --lc-ctype=en_US.utf8
ports:
- 33306:3306
- 5432:5432
networks:
net:
aliases:
- midpoint-data
- net
secrets:
- mp_database_password.txt
volumes:
- midpoint_mysql:/var/lib/mysql
- midpoint_data:/var/lib/mysqlmounted
environment:
- CREATE_NEW_DATABASE=if_needed
- midpoint_data:/var/lib/postgresql/data

midpoint_server:
build: ./midpoint_server/
@@ -14,7 +14,7 @@
xmlns:ri="http://midpoint.evolveum.com/xml/ns/public/resource/instance-3"
xmlns:icfc="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/connector-schema-3"
xmlns:rest="http://midpoint.evolveum.com/xml/ns/public/connector/icf-1/bundle/com.evolveum.polygon.connector-grouper-rest/com.evolveum.polygon.connector.grouper.rest.GrouperConnector"
xmlns:conf="http://midpoint.evolveum.com/xml/ns/public/connector/builtin-1/bundle/com.evolveum.midpoint.provisioning.ucf.impl.builtin.async/AsyncUpdateConnector"
xmlns:conf="http://midpoint.evolveum.com/xml/ns/public/connector/builtin-1/bundle/com.evolveum.midpoint.provisioning.ucf.impl.builtin.async.update/AsyncUpdateConnector"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

@@ -26,6 +26,12 @@
<level>ERROR</level>
<package>ro.isdc.wro.extensions.processor.css.Less4jProcessor</package>
</classLogger>
<classLogger>
<!-- disabled because INFO log during of creating
new authentication filter chain -->
<level>OFF</level>
<package>org.springframework.security.web.DefaultSecurityFilterChain</package>
</classLogger>
<classLogger>
<!-- disabled because of MID-744, helper insert messages on ERROR
level which should not be there (probably should be on TRACE) -->
@@ -47,7 +53,7 @@
<level>WARN</level>
<package>org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl</package>
</classLogger>
<!-- Diesabled because of MID-4636 -->
<!-- Disabled because of MID-4636 -->
<classLogger>
<level>OFF</level>
<package>org.hibernate.internal.ExceptionMapperStandardImpl</package>
@@ -246,8 +252,8 @@
<adminGuiConfiguration>
<userDashboardLink>
<targetUrl>/self/profile</targetUrl>
<label>Profile</label>
<description>View/edit your profile</description>
<label>PageSelfDashboard.profile</label>
<description>PageSelfDashboard.profile.description</description>
<icon>
<cssClass>fa fa-user</cssClass>
</icon>
@@ -257,8 +263,8 @@
</userDashboardLink>
<userDashboardLink>
<targetUrl>/self/credentials</targetUrl>
<label>Credentials</label>
<description>View/edit your credentials</description>
<label>PageSelfDashboard.credentials</label>
<description>PageSelfDashboard.credentials.description</description>
<icon>
<cssClass>fa fa-shield</cssClass>
</icon>
@@ -268,7 +274,7 @@
</userDashboardLink>
<userDashboardLink>
<targetUrl>/admin/users</targetUrl>
<label>List users</label>
<label>PageSelfDashboard.listUsers</label>
<icon>
<cssClass>fa fa-users</cssClass>
</icon>
@@ -277,7 +283,7 @@
</userDashboardLink>
<userDashboardLink>
<targetUrl>/admin/resources</targetUrl>
<label>List resources</label>
<label>PageSelfDashboard.listResources</label>
<icon>
<cssClass>fa fa-database</cssClass>
</icon>
@@ -290,7 +296,12 @@
<display>
<label>My cases</label>
<!-- We need to explicitly specify plural label here. Otherwise it will be overwritten by a plural label from archetype. -->
<pluralLabel>My cases</pluralLabel>
<pluralLabel>
<orig>My cases</orig>
<translation>
<key>MyCases.title</key>
</translation>
</pluralLabel>
<singularLabel>My case</singularLabel>
<icon>
<cssClass>fe fe-case-object</cssClass>
@@ -308,7 +319,12 @@
<display>
<label>Manual cases</label> <!-- "Manual provisioning cases" is too long for the menu -->
<!-- We need to explicitly specify plural label here. Otherwise it will be overwritten by a plural label from archetype. -->
<pluralLabel>All manual cases</pluralLabel>
<pluralLabel>
<orig>All manual cases</orig>
<translation>
<key>AllManualCases.title</key>
</translation>
</pluralLabel>
<singularLabel>Manual case</singularLabel>
<tooltip>Manual provisioning cases</tooltip>
</display>
@@ -324,7 +340,12 @@
<display>
<label>Requests</label> <!-- "Operation requests" is too long for the menu -->
<!-- We need to explicitly specify plural label here. Otherwise it will be overwritten by a plural label from archetype. -->
<pluralLabel>All requests</pluralLabel>
<pluralLabel>
<orig>All requests</orig>
<translation>
<key>AllRequests.title</key>
</translation>
</pluralLabel>
<singularLabel>Request</singularLabel>
<tooltip>Operation requests</tooltip>
</display>
@@ -340,7 +361,12 @@
<display>
<label>Approvals</label> <!-- "Approval cases" is too long for the menu -->
<!-- We need to explicitly specify plural label here. Otherwise it will be overwritten by a plural label from archetype. -->
<pluralLabel>All approvals</pluralLabel>
<pluralLabel>
<orig>All approvals</orig>
<translation>
<key>AllApprovals.title</key>
</translation>
</pluralLabel>
<singularLabel>Approval</singularLabel>
<tooltip>Approval cases</tooltip>
</display>
@@ -455,6 +481,20 @@
<collectionRef oid="00000000-0000-0000-0000-000000000529" relation="org:default" type="c:ArchetypeType"/>
</collection>
</objectCollectionView>
<objectCollectionView>
<identifier>dashboard-reports-view</identifier>
<type>ReportType</type>
<collection>
<collectionRef oid="00000000-0000-0000-0000-000000000170" relation="org:default" type="c:ArchetypeType"/>
</collection>
</objectCollectionView>
<objectCollectionView>
<identifier>collection-reports-view</identifier>
<type>ReportType</type>
<collection>
<collectionRef oid="00000000-0000-0000-0000-000000000171" relation="org:default" type="c:ArchetypeType"/>
</collection>
</objectCollectionView>
</objectCollectionViews>
<objectDetails>
<objectDetailsPage>
@@ -485,6 +525,9 @@
<item>
<c:path>executionStatus</c:path>
</item>
<item>
<c:path>schedulingState</c:path>
</item>
<item>
<c:path>node</c:path>
</item>
@@ -518,6 +561,9 @@
<item>
<c:path>stateBeforeSuspend</c:path>
</item>
<item>
<path>schedulingStateBeforeSuspend</path>
</item>
<item>
<c:path>category</c:path>
</item>
@@ -563,6 +609,10 @@
</objectDetailsPage>
</objectDetails>
<enableExperimentalFeatures>true</enableExperimentalFeatures>
<configurableUserDashboard>
<identifier>admin-dashboard</identifier>
<configurableDashboardRef oid="00000000-0000-0000-0001-000000000001" relation="org:default" type="c:DashboardType"/>
</configurableUserDashboard>
</adminGuiConfiguration>
<workflowConfiguration>
<useLegacyApproversSpecification>never</useLegacyApproversSpecification>
7 changes: 3 additions & 4 deletions demo/shibboleth/.env
@@ -1,15 +1,14 @@
# These parameters can be overridden by setting environment variables before calling docker-compose up
ENV=demo
USERTOKEN=
REPO_DATABASE_TYPE=mariadb
REPO_DATABASE_TYPE=postgresql
REPO_JDBC_URL=default
REPO_HOST=midpoint_data
REPO_PORT=default
REPO_DATABASE=registry
REPO_USER=registry_user
REPO_DATABASE=midpoint
REPO_USER=midpoint
REPO_MISSING_SCHEMA_ACTION=create
REPO_UPGRADEABLE_SCHEMA_ACTION=stop
MP_MEM_MAX=2048m
MP_MEM_INIT=1024m
TIMEZONE=UTC

@@ -1 +1 @@
WJzesbe3poNZ91qIbmR7
WJzesbe3poNZ91qIbmR7
@@ -1 +1 @@
changeit
changeit
22 changes: 12 additions & 10 deletions demo/shibboleth/docker-compose-tests.yml
@@ -4,18 +4,20 @@
version: "3.3"

services:

midpoint_data:
image: tier/mariadb:mariadb10
expose:
- 3306
image: postgres:11
environment:
- POSTGRES_PASSWORD_FILE=/run/secrets/mp_database_password.txt
- POSTGRES_USER=midpoint
- POSTGRES_INITDB_ARGS=--lc-collate=en_US.utf8 --lc-ctype=en_US.utf8
ports:
- 5432:5432
networks:
- net
secrets:
- mp_database_password.txt
volumes:
- midpoint_mysql:/var/lib/mysql
- midpoint_data:/var/lib/mysqlmounted
environment:
- CREATE_NEW_DATABASE=if_needed
- midpoint_data:/var/lib/postgresql/data

midpoint_server:
build: ./midpoint_server/
@@ -75,8 +77,8 @@ services:

directory:
build: ./directory/
expose:
- 389
ports:
- 389:389
networks:
- net
volumes:
16 changes: 9 additions & 7 deletions demo/shibboleth/docker-compose.yml
@@ -1,18 +1,20 @@
version: "3.3"

services:

midpoint_data:
image: tier/mariadb:mariadb10
image: postgres:11
environment:
- POSTGRES_PASSWORD_FILE=/run/secrets/mp_database_password.txt
- POSTGRES_USER=midpoint
- POSTGRES_INITDB_ARGS=--lc-collate=en_US.utf8 --lc-ctype=en_US.utf8
ports:
- 3306:3306
- 5432:5432
networks:
- net
secrets:
- mp_database_password.txt
volumes:
- midpoint_mysql:/var/lib/mysql
- midpoint_data:/var/lib/mysqlmounted
environment:
- CREATE_NEW_DATABASE=if_needed
- midpoint_data:/var/lib/postgresql/data

midpoint_server:
build: ./midpoint_server/
6 changes: 3 additions & 3 deletions demo/simple/.env
@@ -1,12 +1,12 @@
# These parameters can be overridden by setting environment variables before calling docker-compose up
ENV=demo
USERTOKEN=
REPO_DATABASE_TYPE=mariadb
REPO_DATABASE_TYPE=postgresql
REPO_JDBC_URL=default
REPO_HOST=midpoint_data
REPO_PORT=default
REPO_DATABASE=registry
REPO_USER=registry_user
REPO_DATABASE=midpoint
REPO_USER=midpoint
REPO_MISSING_SCHEMA_ACTION=create
REPO_UPGRADEABLE_SCHEMA_ACTION=stop
MP_MEM_MAX=2048m
@@ -1 +1 @@
WJzesbe3poNZ91qIbmR7
WJzesbe3poNZ91qIbmR7
@@ -1 +1 @@
changeit
changeit
15 changes: 9 additions & 6 deletions demo/simple/docker-compose.yml
@@ -2,16 +2,19 @@ version: "3.3"

services:
midpoint_data:
image: tier/mariadb:mariadb10
image: postgres:11
environment:
- POSTGRES_PASSWORD_FILE=/run/secrets/mp_database_password.txt
- POSTGRES_USER=midpoint
- POSTGRES_INITDB_ARGS=--lc-collate=en_US.utf8 --lc-ctype=en_US.utf8
ports:
- 3306:3306
- 5432:5432
networks:
- net
secrets:
- mp_database_password.txt
volumes:
- midpoint_mysql:/var/lib/mysql
- midpoint_data:/var/lib/mysqlmounted
environment:
- CREATE_NEW_DATABASE=if_needed
- midpoint_data:/var/lib/postgresql/data

midpoint_server:
image: tier/midpoint:latest
4 changes: 2 additions & 2 deletions demo/simple/tests/main.bats
@@ -52,7 +52,7 @@ load ../../../library

@test "350 Test DB schema version check" {
echo "Removing version information from m_global_metadata"
docker exec simple_midpoint_data_1 mysql -p123321 registry -e "drop table m_global_metadata"
docker exec simple_midpoint_data_1 psql midpoint midpoint -c "drop table m_global_metadata"

echo "Bringing the containers down"
docker-compose down
@@ -64,7 +64,7 @@ load ../../../library
}

@test "360 Test DB schema upgrade" {
skip 'Not supported for 4.0-SNAPSHOT'
skip 'Not supported for 4.3.2-SNAPSHOT'
echo "Stopping midpoint_server container"
docker stop simple_midpoint_server_1

2 changes: 1 addition & 1 deletion download-midpoint.sh
@@ -10,7 +10,7 @@ else
# But if we need to incorporate interim changes to I2 distribution during
# midPoint development cycle, we can specify concrete file from "midpoint-tier"
# download directory by using its name (like "latest-stable").
MP_VERSION="4.2"
MP_VERSION="4.3.2-SNAPSHOT"
else
MP_VERSION=$tag
fi

0 comments on commit be3b3c8

Please sign in to comment.