2017-11-23 10:56:24 +01:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
curdir=$(dirname "$(readlink -f "$0")")
|
|
|
|
|
|
|
|
docker=$1
|
|
|
|
|
|
|
|
# Build docker image
|
|
|
|
"$curdir/docker_tool.py" build -d "$docker" -t openrw_build_image
|
|
|
|
|
|
|
|
# Start docker container + add travis user
|
2018-08-13 20:06:06 +02:00
|
|
|
"$curdir/docker_tool.py" create -t openrw_build_image -n openrw_builder -U travis \
|
|
|
|
-e \
|
|
|
|
NAME_SUFFIX=$NAME_SUFFIX \
|
2018-11-20 06:51:34 +01:00
|
|
|
CI=$CI \
|
2018-08-13 20:06:06 +02:00
|
|
|
TRAVIS=$TRAVIS \
|
2018-11-20 06:51:34 +01:00
|
|
|
SHIPPABLE=$SHIPPABLE \
|
|
|
|
CODECOV_ENV=$CODECOV_ENV \
|
|
|
|
CODECOV_TOKEN=$CODECOV_TOKEN \
|
|
|
|
CODECOV_URL=$CODECOV_URL \
|
|
|
|
CODECOV_SLUG=$CODECOV_SLUG \
|
2018-08-13 20:06:06 +02:00
|
|
|
TRAVIS_REPO_SLUG=$TRAVIS_REPO_SLUG \
|
|
|
|
TRAVIS_BRANCH=$TRAVIS_BRANCH \
|
2018-11-20 06:51:34 +01:00
|
|
|
TRAVIS_COMMIT=$TRAVIS_COMMIT \
|
|
|
|
TRAVIS_JOB_NUMBER=$TRAVIS_JOB_NUMBER \
|
|
|
|
TRAVIS_PULL_REQUEST=$TRAVIS_PULL_REQUEST \
|
|
|
|
TRAVIS_JOB_ID=$TRAVIS_JOB_ID \
|
|
|
|
TRAVIS_TAG=$TRAVIS_TAG \
|
|
|
|
TRAVIS_OS_NAME=$TRAVIS_OS_NAME \
|
|
|
|
TRAVIS_EVENT_TYPE=$TRAVIS_EVENT_TYPE \
|
2018-08-13 20:06:06 +02:00
|
|
|
USE_CONAN=$USE_CONAN \
|
2018-11-20 06:51:34 +01:00
|
|
|
TEST_COVERAGE=$TEST_COVERAGE \
|
2018-08-27 19:36:47 +02:00
|
|
|
ALSOFT_DRIVERS=null \
|
2018-08-30 03:53:21 +02:00
|
|
|
CC=$CC \
|
|
|
|
CXX=$CXX \
|
2018-08-13 20:06:06 +02:00
|
|
|
DEBUG=$DEBUG \
|
|
|
|
XDG_RUNTIME_DIR=/tmp
|
2017-11-23 10:56:24 +01:00
|
|
|
|
|
|
|
# execute test
|
2018-08-30 03:53:21 +02:00
|
|
|
"$curdir/docker_tool.py" exec -n openrw_builder -U travis -- /bin/bash -c \
|
2018-11-20 06:51:34 +01:00
|
|
|
"ctest -VV -S /src/cmake/ctest/script_ci.ctest"
|