From e5e285696f5c68325273936104fc1d70b6459a55 Mon Sep 17 00:00:00 2001 From: Ingvar Stepanyan Date: Thu, 13 Jan 2022 17:54:29 +0000 Subject: [PATCH] Remove -it from `docker run` on CI --- build.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index e0d45b8..df5e54c 100755 --- a/build.sh +++ b/build.sh @@ -16,8 +16,15 @@ # License along with this library; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA +if [[ -v CI ]] +then + DOCKER_INTERACTIVE_OPTS="" +else + DOCKER_INTERACTIVE_OPTS="-it" +fi + docker build -t web-gphoto2 - < Dockerfile -docker run --rm -it \ +docker run --rm $DOCKER_INTERACTIVE_OPTS \ -v $PWD:/src \ -u $(id -u):$(id -g) \ web-gphoto2 \