From a770814dec5a7a0daa53b4c2b1e8328fdb867146 Mon Sep 17 00:00:00 2001 From: Toby Bellwood Date: Fri, 4 Nov 2022 10:40:55 +1100 Subject: [PATCH 1/2] open/elastic search tests --- helpers/TESTING_dockercompose.md | 14 ++++++++++++++ helpers/docker-compose.yml | 16 ++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/helpers/TESTING_dockercompose.md b/helpers/TESTING_dockercompose.md index ffd9ade6f..72e77f8b7 100644 --- a/helpers/TESTING_dockercompose.md +++ b/helpers/TESTING_dockercompose.md @@ -27,6 +27,7 @@ docker run --rm --net all-images_default jwilder/dockerize dockerize -wait tcp:/ docker run --rm --net all-images_default jwilder/dockerize dockerize -wait tcp://postgres-14:5432 -timeout 1m docker run --rm --net all-images_default jwilder/dockerize dockerize -wait tcp://mongo:27017 -timeout 1m docker run --rm --net all-images_default jwilder/dockerize dockerize -wait tcp://rabbitmq:15672 -timeout 1m +docker run --rm --net all-images_default jwilder/dockerize dockerize -wait tcp://opensearch-2:9200 -timeout 1m ``` Verification commands @@ -267,6 +268,19 @@ docker-compose exec -T ruby-3.1 sh -c "ruby -v" | grep "3.1" # ruby-3.1 should be serving content docker-compose exec -T commons sh -c "curl ruby-3.1:3000/tmp/" | grep "ruby 3.1" + +# opensearch-2 should have opensearch 2 +docker-compose exec -T commons sh -c "curl opensearch-2:9200" | grep number | grep "2." + +# opensearch-2 should be healthy +docker-compose exec -T commons sh -c "curl opensearch-2:9200/_cluster/health" | json_pp | grep status | grep green + +# elasticsearch-7 should have elasticsearch 7 +docker-compose exec -T commons sh -c "curl elasticsearch-7:9200" | grep number | grep "7." + +# elasticsearch-7 should be healthy +docker-compose exec -T commons sh -c "curl elasticsearch-7:9200/_cluster/health" | json_pp | grep status | grep green + ``` Destroy tests diff --git a/helpers/docker-compose.yml b/helpers/docker-compose.yml index a4a85979e..e9a167560 100644 --- a/helpers/docker-compose.yml +++ b/helpers/docker-compose.yml @@ -206,3 +206,19 @@ services: ports: - "8080" # exposes the port 8080 with a random local port, find it with `docker-compose port varnish-7 8080` << : *default-user # uses the defined user from top + + opensearch-2: + image: testlagoon/opensearch-2:latest + labels: + lando.type: opensearch + ports: + - "9200" # exposes the port 8080 with a random local port, find it with `docker-compose port nginx 8080` + << : *default-user # uses the defined user from top + + elasticsearch-7: + image: testlagoon/elasticsearch-7:latest + labels: + lando.type: elasticsearch + ports: + - "9200" # exposes the port 8080 with a random local port, find it with `docker-compose port nginx 8080` + << : *default-user # uses the defined user from top From 3b806da85aff343a8a5b636e7e270c4cb2e98579 Mon Sep 17 00:00:00 2001 From: Toby Bellwood Date: Fri, 11 Nov 2022 09:42:42 +1100 Subject: [PATCH 2/2] update test images --- helpers/TESTING_dockercompose.md | 1 - helpers/docker-compose.yml | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/helpers/TESTING_dockercompose.md b/helpers/TESTING_dockercompose.md index 72e77f8b7..7b4358322 100644 --- a/helpers/TESTING_dockercompose.md +++ b/helpers/TESTING_dockercompose.md @@ -280,7 +280,6 @@ docker-compose exec -T commons sh -c "curl elasticsearch-7:9200" | grep number | # elasticsearch-7 should be healthy docker-compose exec -T commons sh -c "curl elasticsearch-7:9200/_cluster/health" | json_pp | grep status | grep green - ``` Destroy tests diff --git a/helpers/docker-compose.yml b/helpers/docker-compose.yml index e9a167560..dac6fb786 100644 --- a/helpers/docker-compose.yml +++ b/helpers/docker-compose.yml @@ -208,7 +208,7 @@ services: << : *default-user # uses the defined user from top opensearch-2: - image: testlagoon/opensearch-2:latest + image: uselagoon/opensearch-2:latest labels: lando.type: opensearch ports: @@ -216,7 +216,7 @@ services: << : *default-user # uses the defined user from top elasticsearch-7: - image: testlagoon/elasticsearch-7:latest + image: uselagoon/elasticsearch-7:latest labels: lando.type: elasticsearch ports: