2020-04-30 18:52:54 +07:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
|
|
|
|
main() {
|
2020-08-28 02:39:24 +07:00
|
|
|
cd "$(dirname "$0")/../../.."
|
|
|
|
source ./ci/lib.sh
|
2020-04-30 18:52:54 +07:00
|
|
|
|
|
|
|
docker run \
|
|
|
|
-it \
|
2020-08-28 02:39:24 +07:00
|
|
|
--rm \
|
|
|
|
-v "$PWD:/src" \
|
|
|
|
-w /src \
|
|
|
|
-p 127.0.0.1:8080:8080 \
|
2020-09-03 13:16:57 +07:00
|
|
|
-u "$(id -u):$(id -g)" \
|
|
|
|
-e CI \
|
2020-08-28 02:39:24 +07:00
|
|
|
"$(docker_build ./ci/images/debian8)" \
|
|
|
|
"$@"
|
2020-04-30 18:52:54 +07:00
|
|
|
}
|
|
|
|
|
2020-08-28 02:39:24 +07:00
|
|
|
docker_build() {
|
|
|
|
docker build "$@" >&2
|
|
|
|
docker build -q "$@"
|
2020-04-30 18:52:54 +07:00
|
|
|
}
|
|
|
|
|
|
|
|
main "$@"
|