Attempt to unbork interactive breakage
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
See #204.
This commit is contained in:
parent
349b468140
commit
3d5d3ff3ac
20
abra
20
abra
|
@ -1846,10 +1846,12 @@ sub_app_run(){
|
||||||
RUN_USER="-u $abra___user"
|
RUN_USER="-u $abra___user"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
local -a ARGS="${ARGS:-""}"
|
||||||
|
|
||||||
if [ "$abra___no_tty" = "true" ]; then
|
if [ "$abra___no_tty" = "true" ]; then
|
||||||
ARGS="-i"
|
ARGS+=" -i"
|
||||||
else
|
else
|
||||||
ARGS="-it"
|
ARGS+=" -it"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CONTAINER=$(docker container ls --format "table {{.ID}},{{.Names}}" \
|
CONTAINER=$(docker container ls --format "table {{.ID}},{{.Names}}" \
|
||||||
|
@ -1862,11 +1864,15 @@ sub_app_run(){
|
||||||
|
|
||||||
debug "Using container ID ${CONTAINER}"
|
debug "Using container ID ${CONTAINER}"
|
||||||
|
|
||||||
# 3wc: we want the "splitting" that shellcheck warns us about, so that -u and
|
# shellcheck disable=SC2145
|
||||||
# $RUN_USER aren't treated as a single argument:
|
debug "Running command: docker exec $RUN_USER $ARGS $CONTAINER $@"
|
||||||
|
|
||||||
# shellcheck disable=SC2086
|
# shellcheck disable=SC2086
|
||||||
docker exec $RUN_USER $ARGS "$CONTAINER" "$@"
|
docker exec $RUN_USER $ARGS "$CONTAINER" "$@"
|
||||||
|
|
||||||
|
# shellcheck disable=SC2181
|
||||||
|
if [[ $? != 0 ]]; then exit 1; fi
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2153,14 +2159,14 @@ sub_recipe_lint() {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check that at least one service has Traefik enabled
|
# Check that at least one service has Traefik enabled
|
||||||
if $YQ e '.services.*.deploy.labels.[] == "traefik.enable=true"' "$compose_file" | grep -q true; then
|
if $YQ e '.services.*.deploy.labels.[] == "traefik.enable=true"' "$compose_file" | grep -q true; then
|
||||||
info "Found at least one Traefik-enabled service"
|
info "Found at least one Traefik-enabled service"
|
||||||
else
|
else
|
||||||
warning "Can't find any Traefik-enabled service"
|
warning "Can't find any Traefik-enabled service"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Healthcheck check (check)
|
# Healthcheck check (check)
|
||||||
if $YQ e -e '.services.*.healthcheck' "$compose_file" > /dev/null 2>&1; then
|
if $YQ e -e '.services.*.healthcheck' "$compose_file" > /dev/null 2>&1; then
|
||||||
info "Found a healthcheck for at least one service."
|
info "Found a healthcheck for at least one service."
|
||||||
else
|
else
|
||||||
warning "Can't find any healthchecks."
|
warning "Can't find any healthchecks."
|
||||||
|
|
Reference in New Issue