diff --git a/docker-internal/Dockerfile b/docker-internal/Dockerfile index d70099c79..d6a9cb93a 100644 --- a/docker-internal/Dockerfile +++ b/docker-internal/Dockerfile @@ -53,6 +53,7 @@ RUN set -eux; \ grep -E '^ *createBoolConfig[(]"protected-mode",.*, *1 *,.*[)],$' ./src/config.cpp; \ sed -ri 's!^( *createBoolConfig[(]"protected-mode",.*, *)1( *,.*[)],)$!\10\2!' ./src/config.cpp; \ grep -E '^ *createBoolConfig[(]"protected-mode",.*, *0 *,.*[)],$' ./src/config.cpp; \ + make distclean; \ make -j$([ -z "$MAKE_JOBS" ] && nproc || echo "$MAKE_JOBS") BUILD_TLS=yes NO_LICENSE_CHECK=yes; \ cd src; \ strip keydb-cli keydb-benchmark keydb-check-rdb keydb-check-aof keydb-diagnostic-tool keydb-sentinel; \ diff --git a/docker-internal/README.md b/docker-internal/README.md index f6a8d7b6d..3eb861202 100644 --- a/docker-internal/README.md +++ b/docker-internal/README.md @@ -24,7 +24,7 @@ Please note that directories are relative to the docker build context. You can u ### Pushing #### AWS -There is a script ./build-and-publish.sh to build and push image. This script will push images to caching-infra AWS account and caching-infra GCP project. +There is a script ./build-and-publish.sh to build and push image. This script will push images to caching-infra AWS account and caching-infra GCP project. Make sure this script is not run using root/sudo otherwise you may not be able to access the correct AWS profile, even if everything else is configured correctly. If you are pushing to ECR, then you need to add this profile config in your ```~/.aws/config```: diff --git a/docker-internal/build-and-publish.sh b/docker-internal/build-and-publish.sh index 3ece75387..11eb05650 100755 --- a/docker-internal/build-and-publish.sh +++ b/docker-internal/build-and-publish.sh @@ -1,4 +1,4 @@ -#!/bin/sh -e +#!/bin/bash -e set -o pipefail