diff options
author | waynedunican <wayne.dunican@est.tech> | 2024-04-18 17:09:52 +0100 |
---|---|---|
committer | waynedunican <wayne.dunican@est.tech> | 2024-04-23 15:58:19 +0100 |
commit | aa86c67092daa5bd10dd6506fd33f3a6233dd281 (patch) | |
tree | b94fd47a88548742a16a10ba01e2f1402b3437c7 /compose | |
parent | cebb4172163dc04b43be7e34d9a4b374370492f8 (diff) |
Add ACM db upgrade/downgrade to db-migrator
Issue-ID: POLICY-4934
Change-Id: Ic515eb1b2d549fdd91cff22ed6f589b673748657
Signed-off-by: waynedunican <wayne.dunican@est.tech>
Diffstat (limited to 'compose')
-rw-r--r-- | compose/config/clamp/AcRuntimeParameters.yaml | 2 | ||||
-rw-r--r-- | compose/docker-compose.yml | 25 |
2 files changed, 24 insertions, 3 deletions
diff --git a/compose/config/clamp/AcRuntimeParameters.yaml b/compose/config/clamp/AcRuntimeParameters.yaml index 262f10c6..c61428da 100644 --- a/compose/config/clamp/AcRuntimeParameters.yaml +++ b/compose/config/clamp/AcRuntimeParameters.yaml @@ -18,7 +18,7 @@ spring: maximumPoolSize: 10 jpa: hibernate: - ddl-auto: update + ddl-auto: none naming: physical-strategy: org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl implicit-strategy: org.onap.policy.common.spring.utils.CustomImplicitNamingStrategy diff --git a/compose/docker-compose.yml b/compose/docker-compose.yml index 0264b290..60ed0bc7 100644 --- a/compose/docker-compose.yml +++ b/compose/docker-compose.yml @@ -35,7 +35,7 @@ services: container_name: policy-db-migrator hostname: policy-db-migrator depends_on: - - mariadb + - mariadb expose: - 6824 env_file: ./config/db/db.conf @@ -51,6 +51,27 @@ services: '/opt/app/policy/bin/db_migrator_policy_init.sh', 'mariadb', '3306' ] + policy-db-migrator-clamp: + image: ${CONTAINER_LOCATION}onap/policy-db-migrator:${POLICY_DOCKER_VERSION} + container_name: policy-db-migrator-clamp + hostname: policy-db-migrator-clamp + depends_on: + - mariadb + expose: + - 6824 + env_file: ./config/db/db.conf + environment: + SQL_DB: clampacm + SQL_HOST: mariadb + volumes: + - ./config/db-migrator/init.sh:/opt/app/policy/bin/db_migrator_policy_init.sh:ro + - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro + entrypoint: /opt/app/policy/bin/wait_for_port.sh + command: [ + '-c', + '/opt/app/policy/bin/db_migrator_policy_init.sh', + 'mariadb', '3306' + ] simulator: image: ${CONTAINER_LOCATION}onap/policy-models-simulator:${POLICY_MODELS_VERSION} container_name: simulator @@ -240,7 +261,7 @@ services: image: ${CONTAINER_LOCATION}onap/policy-clamp-runtime-acm:${POLICY_CLAMP_VERSION} container_name: policy-clamp-runtime-acm depends_on: - - mariadb + - policy-db-migrator-clamp - kafka - policy-clamp-ac-http-ppnt - policy-clamp-ac-k8s-ppnt |