mirror of
https://github.com/php-curl-class/php-curl-class.git
synced 2026-08-30 04:01:47 +00:00
Add script to run tests in all docker images
This commit is contained in:
Executable
+15
@@ -0,0 +1,15 @@
|
||||
# Run image to create container.
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
set -x
|
||||
cd "${SCRIPT_DIR}/../../.."
|
||||
project_dir="${PWD}"
|
||||
|
||||
docker start "php56" ||
|
||||
docker run \
|
||||
--detach \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name="php56" \
|
||||
--tty \
|
||||
"php-curl-class/php56"
|
||||
Executable
+3
@@ -0,0 +1,3 @@
|
||||
# Stop container.
|
||||
|
||||
docker stop "php56"
|
||||
@@ -8,7 +8,7 @@ project_dir="${PWD}"
|
||||
docker run \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name=php56 \
|
||||
--name="php56" \
|
||||
--rm \
|
||||
--tty \
|
||||
"php-curl-class/php56" /bin/bash
|
||||
@@ -0,0 +1,15 @@
|
||||
# Run image to create container.
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
set -x
|
||||
cd "${SCRIPT_DIR}/../../.."
|
||||
project_dir="${PWD}"
|
||||
|
||||
docker start "php70" ||
|
||||
docker run \
|
||||
--detach \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name="php70" \
|
||||
--tty \
|
||||
"php-curl-class/php70"
|
||||
@@ -0,0 +1,3 @@
|
||||
# Stop container.
|
||||
|
||||
docker stop "php70"
|
||||
@@ -8,7 +8,7 @@ project_dir="${PWD}"
|
||||
docker run \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name=php70 \
|
||||
--name="php70" \
|
||||
--rm \
|
||||
--tty \
|
||||
"php-curl-class/php70" /bin/bash
|
||||
@@ -0,0 +1,15 @@
|
||||
# Run image to create container.
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
set -x
|
||||
cd "${SCRIPT_DIR}/../../.."
|
||||
project_dir="${PWD}"
|
||||
|
||||
docker start "php71" ||
|
||||
docker run \
|
||||
--detach \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name="php71" \
|
||||
--tty \
|
||||
"php-curl-class/php71"
|
||||
@@ -0,0 +1,3 @@
|
||||
# Stop container.
|
||||
|
||||
docker stop "php71"
|
||||
@@ -8,7 +8,7 @@ project_dir="${PWD}"
|
||||
docker run \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name=php71 \
|
||||
--name="php71" \
|
||||
--rm \
|
||||
--tty \
|
||||
"php-curl-class/php71" /bin/bash
|
||||
@@ -0,0 +1,15 @@
|
||||
# Run image to create container.
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
set -x
|
||||
cd "${SCRIPT_DIR}/../../.."
|
||||
project_dir="${PWD}"
|
||||
|
||||
docker start "php72" ||
|
||||
docker run \
|
||||
--detach \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name="php72" \
|
||||
--tty \
|
||||
"php-curl-class/php72"
|
||||
@@ -0,0 +1,3 @@
|
||||
# Stop container.
|
||||
|
||||
docker stop "php72"
|
||||
@@ -8,7 +8,7 @@ project_dir="${PWD}"
|
||||
docker run \
|
||||
--interactive \
|
||||
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
|
||||
--name=php72 \
|
||||
--name="php72" \
|
||||
--rm \
|
||||
--tty \
|
||||
"php-curl-class/php72" /bin/bash
|
||||
Executable
+12
@@ -0,0 +1,12 @@
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
cd "${SCRIPT_DIR}"
|
||||
|
||||
for d in "dockerfiles/"* ; do
|
||||
echo "Running ${d}" &&
|
||||
pushd "${d}" &&
|
||||
bash "1_build.sh" &&
|
||||
bash "2_start.sh" &&
|
||||
bash "3_test.sh" &&
|
||||
bash "4_stop.sh" &&
|
||||
popd
|
||||
done
|
||||
Reference in New Issue
Block a user