From 7968dcbf793fb905d2606971720f8598330fa034 Mon Sep 17 00:00:00 2001 From: virgilchiriac Date: Mon, 1 Jul 2024 09:47:07 +0200 Subject: [PATCH 1/4] BC-7461 - upgrade to mongo 6 --- compose-files/docker-compose.yml | 8 ++++---- envs/default.env | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compose-files/docker-compose.yml b/compose-files/docker-compose.yml index c0192b1..7f861c2 100644 --- a/compose-files/docker-compose.yml +++ b/compose-files/docker-compose.yml @@ -21,7 +21,7 @@ services: ### Schul-Cloud Server ### mongodb-primary: - image: mongo:5.0.26 ## change tag in version.env + image: mongo:6.0.15 ## change tag in version.env container_name: mongodb-primary ports: - "27017:27017" @@ -34,7 +34,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-secondary: - image: mongo:5.0.26 ## change tag in version.env + image: mongo:6.0.15 ## change tag in version.env container_name: mongodb-secondary ports: - "27017" @@ -45,7 +45,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-arbiter: - image: mongo:5.0.26 ## change tag in version.env + image: mongo:6.0.15 ## change tag in version.env container_name: mongodb-arbiter ports: - "27017" @@ -56,7 +56,7 @@ services: command: --bind_ip_all --replSet rs0 mongosetup: - image: mongo:5.0.26 + image: mongo:6.0.15 depends_on: - mongodb-primary - mongodb-secondary diff --git a/envs/default.env b/envs/default.env index 8ae38a8..1a5d420 100644 --- a/envs/default.env +++ b/envs/default.env @@ -4,5 +4,5 @@ COMPOSE_FILES_PATH=./compose-files POSTGRES_DOCKER_TAG=11.9 REDIS_DOCKER_TAG=6.0.8 -MONGO_DOCKER_TAG=5.0.26 +MONGO_DOCKER_TAG=6.0.15 RABBITMQ_DOCKER_TAG=3.8.9-management From e85570e332e0c192ec555149fca3e1d6081aa905 Mon Sep 17 00:00:00 2001 From: virgilchiriac Date: Fri, 5 Jul 2024 19:02:48 +0200 Subject: [PATCH 2/4] fix yml --- compose-files/docker-compose.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/compose-files/docker-compose.yml b/compose-files/docker-compose.yml index 7f861c2..7665108 100644 --- a/compose-files/docker-compose.yml +++ b/compose-files/docker-compose.yml @@ -21,7 +21,7 @@ services: ### Schul-Cloud Server ### mongodb-primary: - image: mongo:6.0.15 ## change tag in version.env + image: mongo:6.0.15 container_name: mongodb-primary ports: - "27017:27017" @@ -34,7 +34,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-secondary: - image: mongo:6.0.15 ## change tag in version.env + image: mongo:6.0.15 container_name: mongodb-secondary ports: - "27017" @@ -45,7 +45,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-arbiter: - image: mongo:6.0.15 ## change tag in version.env + image: mongo:6.0.15 container_name: mongodb-arbiter ports: - "27017" @@ -67,7 +67,7 @@ services: entrypoint: [ "bash", "/scripts/mongo_setup.sh" ] redis: - image: redis:${REDIS_DOCKER_TAG:-latest} ## change tag in version.env + image: redis:${REDIS_DOCKER_TAG:-latest} container_name: redis command: ["redis-server", "--appendonly", "yes"] hostname: redis From 4d4c5bb0cf3c3e0caa96963fadcac4652e446f41 Mon Sep 17 00:00:00 2001 From: virgilchiriac Date: Mon, 8 Jul 2024 17:13:42 +0200 Subject: [PATCH 3/4] replace removed mongo command with new mongosh --- scripts/mongo_setup.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/mongo_setup.sh b/scripts/mongo_setup.sh index c21e9b7..b458c17 100644 --- a/scripts/mongo_setup.sh +++ b/scripts/mongo_setup.sh @@ -2,8 +2,8 @@ sleep 10 echo SETUP.sh time now: `date +"%T" ` -mongo --host mongodb-primary:27017 --eval 'rs.initiate({_id: "rs0", members: [{_id: 0, host: "mongodb-primary:27017" }]})' -mongo --host mongodb-primary:27017 << EOF +mongosh --host mongodb-primary:27017 --eval 'rs.initiate({_id: "rs0", members: [{_id: 0, host: "mongodb-primary:27017" }]})' +mongosh --host mongodb-primary:27017 << EOF var cfg = { "_id": "rs0", "version": 1, From 074e08eb1157059eeef6dcc5c1a01c4129d82f51 Mon Sep 17 00:00:00 2001 From: MartinSchuhmacher Date: Wed, 10 Jul 2024 15:39:01 +0200 Subject: [PATCH 4/4] adjusting used mongo version --- compose-files/docker-compose.yml | 8 ++++---- envs/default.env | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compose-files/docker-compose.yml b/compose-files/docker-compose.yml index 7665108..f25938a 100644 --- a/compose-files/docker-compose.yml +++ b/compose-files/docker-compose.yml @@ -21,7 +21,7 @@ services: ### Schul-Cloud Server ### mongodb-primary: - image: mongo:6.0.15 + image: mongo:6.0.16 container_name: mongodb-primary ports: - "27017:27017" @@ -34,7 +34,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-secondary: - image: mongo:6.0.15 + image: mongo:6.0.16 container_name: mongodb-secondary ports: - "27017" @@ -45,7 +45,7 @@ services: command: --bind_ip_all --replSet rs0 mongodb-arbiter: - image: mongo:6.0.15 + image: mongo:6.0.16 container_name: mongodb-arbiter ports: - "27017" @@ -56,7 +56,7 @@ services: command: --bind_ip_all --replSet rs0 mongosetup: - image: mongo:6.0.15 + image: mongo:6.0.16 depends_on: - mongodb-primary - mongodb-secondary diff --git a/envs/default.env b/envs/default.env index 1a5d420..79108f5 100644 --- a/envs/default.env +++ b/envs/default.env @@ -4,5 +4,5 @@ COMPOSE_FILES_PATH=./compose-files POSTGRES_DOCKER_TAG=11.9 REDIS_DOCKER_TAG=6.0.8 -MONGO_DOCKER_TAG=6.0.15 +MONGO_DOCKER_TAG=6.0.16 RABBITMQ_DOCKER_TAG=3.8.9-management