Sha256: 1d8e4dc59fe8168d62a5def2a6687c352bcc4f264151ec63dfc333a23f04fc38

Contents?: true

Size: 1.86 KB

Versions: 16

Compression:

Stored size: 1.86 KB

Contents

#!/usr/bin/env bash
#
# Called by entry point `run-test` use this script to add your repository specific test commands
#
# Once called Elasticsearch is up and running
#
# Its recommended to call `imports.sh` as defined here so that you get access to all variables defined there
#
# Any parameters that test-matrix.yml defines should be declared here with appropiate defaults

script_path=$(dirname $(realpath -s $0))
source $script_path/functions/imports.sh
set -euo pipefail

echo -e "\033[34;1mINFO:\033[0m VERSION: ${STACK_VERSION}\033[0m"
echo -e "\033[34;1mINFO:\033[0m TEST_SUITE: ${TEST_SUITE}\033[0m"
echo -e "\033[34;1mINFO:\033[0m RUBY_VERSION: ${RUBY_VERSION}\033[0m"
echo -e "\033[34;1mINFO:\033[0m RUNSCRIPTS: ${RUNSCRIPTS}\033[0m"
echo -e "\033[34;1mINFO:\033[0m URL: ${elasticsearch_url}\033[0m"
echo -e "\033[34;1mINFO:\033[0m SERVICE: ${SERVICE}\033[0m"

echo -e "\033[34;1mINFO:\033[0m pinging Elasticsearch ..\033[0m"
curl --insecure --fail $external_elasticsearch_url/_cluster/health?pretty

if [[ "$RUNSCRIPTS" = *"enterprise-search"* ]]; then
  enterprise_search_url="http://localhost:3002"
  echo -e "\033[34;1mINFO:\033[0m pinging Enterprise Search ..\033[0m"
  curl -I --fail $enterprise_search_url
fi

echo -e "\033[32;1mSUCCESS:\033[0m successfully started the ${STACK_VERSION} stack.\033[0m"

echo -e "\033[32;1mBUILD: \033[31mRuby \e[0m container.\033[0m"

docker build \
       --file .ci/Dockerfile \
       --tag elastic/enterprise-search-ruby \
       --build-arg RUBY_VERSION=${RUBY_VERSION} \
       .

echo -e "\033[32;1mRUN: \033[31mRuby \e[0m container.\033[0m"

docker run \
       --network ${network_name} \
       --name enterprise-search-ruby \
       --env "ELASTIC_ENTERPRISE_HOST=http://${CONTAINER_NAME}:3002" \
       --rm \
       --volume `pwd`:/code/enterprise-search-ruby \
       elastic/enterprise-search-ruby \
       rake spec:integration:${SERVICE}

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
elastic-enterprise-search-8.6.0 .ci/run-repository.sh
elastic-enterprise-search-8.5.0 .ci/run-repository.sh
elastic-enterprise-search-7.17.1 .ci/run-repository.sh
elastic-enterprise-search-8.4.0 .ci/run-repository.sh
elastic-enterprise-search-8.3.0 .ci/run-repository.sh
elastic-enterprise-search-8.2.1 .ci/run-repository.sh
elastic-enterprise-search-8.1.1 .ci/run-repository.sh
elastic-enterprise-search-8.0.1 .ci/run-repository.sh
elastic-enterprise-search-8.2.0 .ci/run-repository.sh
elastic-enterprise-search-8.1.0 .ci/run-repository.sh
elastic-enterprise-search-8.0.0 .ci/run-repository.sh
elastic-enterprise-search-8.0.0.pre .ci/run-repository.sh
elastic-enterprise-search-7.17.0 .ci/run-repository.sh
elastic-enterprise-search-7.16.0 .ci/run-repository.sh
elastic-enterprise-search-7.15.1 .ci/run-repository.sh
elastic-enterprise-search-7.15.0 .ci/run-repository.sh