1
0
mirror of https://github.com/zokradonh/kopano-docker.git synced 2026-08-11 16:32:59 +00:00

add linting for shell scripts and Dockerfiles

* add hadolint for dockerfile linting
* add hadofile config
* add checks for dockerfiles and shellcheck into makefile
* shellcheck fixes
* add workaround so that .env can be sourced again from version.sh
* hadolint fixes
* print progress of build/run.sh
* fix check for jq in setup.sh

relates to #41 and #26
This commit is contained in:
Felix Bartels
2019-03-14 07:46:54 +01:00
committed by GitHub
parent f5a24f2150
commit 91ccf89765
26 changed files with 133 additions and 79 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
FROM docker:18.09.1
ENV COMPOSE_VERSION "1.23.2"
RUN apk add bash curl expect make nano jq py-pip
RUN apk add --no-cache bash curl expect make nano jq py-pip
RUN pip install --no-cache-dir docker-compose==${COMPOSE_VERSION}
WORKDIR /kopano-docker
CMD ["bash"]
+6 -4
View File
@@ -3,11 +3,13 @@ if [ ! "$(id -u)" -eq 0 ]; then
echo "This script may need to be run as root to be able to use docker/docker-compose through it."
fi
cd "$(dirname "$0")"
cd "$(dirname "$0")" || exit
docker build .
docker run \
--rm -it \
-u $(id -u ${USER}):$(id -g ${USER}) \
-u "$(id -u)":"$(id -g)" \
-v /var/run/docker.sock:/var/run/docker.sock \
-v ${PWD}/..:/kopano-docker/ \
$(docker build -q .) $@
-v "$(pwd)"/..:/kopano-docker/ \
"$(docker build -q .)" "$@"