diff --git a/Makefile b/Makefile index f1a2bf8a8..c1becbc99 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -.PHONY: clean local test linux macos mocks docker push e2e +.PHONY: clean local test linux macos mocks docker pooler push e2e BINARY ?= postgres-operator BUILD_FLAGS ?= -v @@ -97,7 +97,7 @@ docker: $(GENERATED_CRDS) ${DOCKERDIR}/${DOCKERFILE} docker build --rm -t "$(IMAGE_TAG)" -f "${DOCKERDIR}/${DOCKERFILE}" --build-arg VERSION="${VERSION}" --build-arg BASE_IMAGE="${BASE_IMAGE}" . pooler: - docker build --rm -t "$(POOLER_TAG)" -f "pooler/Dockerfile" --build-arg VERSION="${VERSION}" --build-arg BASE_IMAGE="${BASE_IMAGE}" . + cd pooler; docker build --rm -t "$(POOLER_TAG)" --build-arg VERSION="${VERSION}" --build-arg BASE_IMAGE="${BASE_IMAGE}" . indocker-race: docker run --rm -v "${GOPATH}":"${GOPATH}" -e GOPATH="${GOPATH}" -e RACE=1 -w ${PWD} golang:1.25.3 bash -c "make linux" diff --git a/e2e/run.sh b/e2e/run.sh index cd39cdd62..c5daf81f6 100755 --- a/e2e/run.sh +++ b/e2e/run.sh @@ -26,13 +26,12 @@ echo "Kubeconfig path: ${kubeconfig_path}" function pull_images(){ operator_tag=$(git describe --tags --always --dirty) - declare -A images=( - ["postgres-operator"]="ghcr.io/zalando/postgres-operator:${operator_tag}" - ["pooler"]="ghcr.io/zalando/postgres-operator/pgbouncer:${operator_tag}" - ) + components=("postgres-operator" "pooler") + image_urls=("ghcr.io/zalando/postgres-operator:${operator_tag}" "ghcr.io/zalando/postgres-operator/pgbouncer:${operator_tag}") - for component in "${!images[@]}"; do - image="${images[$component]}" + for i in "${!components[@]}"; do + component="${components[$i]}" + image="${image_urls[$i]}" if [[ -z $(docker images -q "$image") ]]; then echo "Pulling $component image: $image"