From eee9c7426bbc6d7371e10b5b89aa9188746ebec5 Mon Sep 17 00:00:00 2001 From: anirudhwarrier <12178754+anirudhwarrier@users.noreply.github.com> Date: Tue, 30 Jul 2024 14:31:38 +0400 Subject: [PATCH] update tests Dockerfile to copy only required files --- integration-tests/test.Dockerfile | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/integration-tests/test.Dockerfile b/integration-tests/test.Dockerfile index fc6eefd650c..2e928ab29f8 100644 --- a/integration-tests/test.Dockerfile +++ b/integration-tests/test.Dockerfile @@ -1,10 +1,18 @@ ARG BASE_IMAGE ARG IMAGE_VERSION=latest -FROM ${BASE_IMAGE}:${IMAGE_VERSION} +FROM ${BASE_IMAGE}:${IMAGE_VERSION} AS build-env ARG SUITES=chaos migration performance reorg smoke soak benchmark COPY . testdir/ WORKDIR /go/testdir RUN /go/testdir/integration-tests/scripts/buildTests "${SUITES}" + +FROM ${BASE_IMAGE}:${IMAGE_VERSION} + +RUN mkdir -p /go/testdir/integration-tests/scripts +COPY --from=build-env /go/pkg /go/pkg +COPY --from=build-env /go/testdir/integration-tests/*.test /go/testdir/integration-tests/ +COPY --from=build-env /go/testdir/integration-tests/scripts /go/testdir/integration-tests/scripts/ + ENTRYPOINT ["/go/testdir/integration-tests/scripts/entrypoint"]