demo / run-ci-container.sh
ElmiraManavi
implement demo service in message queue
4b63644
raw
history blame contribute delete
547 Bytes
#!/bin/sh
# parse and export .env.variables.yml
. ./.variables.parse.sh
export BUILDKIT_PROGRESS=plain
# special case for windows
DOCKER_PREFIX=$(which winpty)
if [ -n "$DOCKER_PREFIX" ]; then
DOCKER_PREFIX="$DOCKER_PREFIX "
fi
# https://superuser.com/questions/344478/bash-execute-command-given-in-commandline-and-dont-exit
${DOCKER_PREFIX}docker run \
--rm\
-ti\
--mount "type=bind,src=/var/run/docker.sock,target=/var/run/docker.sock"\
--mount "type=bind,src=$(pwd),target=/workdir"\
"$IMAGE_CI"\
sh -c "cd /workdir ; exec sh"