diff --git a/script/benchmark/test.sh b/script/benchmark/test.sh index 76bc50309..5f3ab7383 100755 --- a/script/benchmark/test.sh +++ b/script/benchmark/test.sh @@ -133,9 +133,9 @@ echo "Logging to >>> ${LOG_FILE} (will finally be stored under ${OUTPUTDIR})" echo "Benchmarking..." FAIL= if ! ( cd "${CONTEXT}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} \ + docker compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} \ "${BENCHMARKING_NODE}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ + docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ docker exec \ -e BENCHMARK_RUNTIME_MODE -e BENCHMARK_SAMPLES_NUM -e BENCHMARK_PROFILE \ -i "${BENCHMARKING_CONTAINER}" \ @@ -165,7 +165,7 @@ if [ "${FAIL}" != "true" ] ; then fi echo "Cleaning up environment..." -docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v +docker compose -f "${DOCKER_COMPOSE_YAML}" down -v if [ "${FAIL}" == "true" ] ; then exit 1 fi diff --git a/script/cri-containerd/test-stargz.sh b/script/cri-containerd/test-stargz.sh index f247b782c..f9e693bef 100755 --- a/script/cri-containerd/test-stargz.sh +++ b/script/cri-containerd/test-stargz.sh @@ -39,7 +39,7 @@ LOG_FILE=$(mktemp) MIRROR_TMP=$(mktemp -d) function cleanup { ORG_EXIT_CODE="${1}" - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v || true + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v || true rm -rf "${TMP_CONTEXT}" || true rm "${DOCKER_COMPOSE_YAML}" || true rm "${CONTAINERD_CONFIG}" || true @@ -90,7 +90,7 @@ volumes: critest-prepare-containerd-data: critest-prepare-containerd-stargz-grpc-data: EOF -docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate +docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate CONNECTED= for i in $(seq 100) ; do diff --git a/script/cri-o/test-stargz.sh b/script/cri-o/test-stargz.sh index 6fd0adf7e..249086f6a 100755 --- a/script/cri-o/test-stargz.sh +++ b/script/cri-o/test-stargz.sh @@ -38,7 +38,7 @@ LOG_FILE=$(mktemp) MIRROR_TMP=$(mktemp -d) function cleanup { ORG_EXIT_CODE="${1}" - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v || true + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v || true rm -rf "${TMP_CONTEXT}" || true rm "${DOCKER_COMPOSE_YAML}" || true rm "${CRIO_CONFIG}" || true @@ -109,7 +109,7 @@ volumes: critest-prepare-containerd-data: critest-prepare-containerd-stargz-grpc-data: EOF -docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate +docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate retry docker exec "${PREPARE_NODE_NAME}" curl -k --head "http://${REGISTRY_HOST}:5000/v2/" diff --git a/script/criauth/test.sh b/script/criauth/test.sh index 78f5691e1..d258d1a1e 100755 --- a/script/criauth/test.sh +++ b/script/criauth/test.sh @@ -103,11 +103,11 @@ EOF cp "${REPO}/script/criauth/mirror.sh" "${MIRROR_TMP}/mirror.sh" if ! ( cd "${CONTEXT}" && \ docker network create "${REGISTRY_NETWORK}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ + docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ docker exec "${PREPARE_NODE_NAME}" /bin/bash /tools/mirror.sh \ "${TESTIMAGE_ORIGIN}" "${TESTIMAGE}" ) ; then echo "Failed to prepare private registry" - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v docker network rm "${REGISTRY_NETWORK}" exit 1 fi @@ -126,7 +126,7 @@ if ! ( "${CONTEXT}"/run-kind.sh "${KIND_CLUSTER_NAME}" \ "${KIND_KUBECONFIG}" "${TESTIMAGE}" ) ; then FAIL=true fi -docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v +docker compose -f "${DOCKER_COMPOSE_YAML}" down -v kind delete cluster --name "${KIND_CLUSTER_NAME}" docker network rm "${REGISTRY_NETWORK}" diff --git a/script/integration/test.sh b/script/integration/test.sh index d7c21348e..87f243d52 100755 --- a/script/integration/test.sh +++ b/script/integration/test.sh @@ -153,12 +153,12 @@ EOF echo "Testing..." FAIL= if ! ( cd "${CONTEXT}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} \ + docker compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} \ "${CONTAINERD_NODE}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up --abort-on-container-exit ) ; then + docker compose -f "${DOCKER_COMPOSE_YAML}" up --abort-on-container-exit ) ; then FAIL=true fi -docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v +docker compose -f "${DOCKER_COMPOSE_YAML}" down -v if [ "${FAIL}" == "true" ] ; then exit 1 fi diff --git a/script/k3s/test.sh b/script/k3s/test.sh index f75628f38..22cc2e5ff 100755 --- a/script/k3s/test.sh +++ b/script/k3s/test.sh @@ -103,11 +103,11 @@ EOF cp "${REPO}/script/k3s/mirror.sh" "${MIRROR_TMP}/mirror.sh" if ! ( cd "${CONTEXT}" && \ docker network create "${REGISTRY_NETWORK}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ + docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ docker exec "${PREPARE_NODE_NAME}" /bin/bash /tools/mirror.sh \ "${TESTIMAGE_ORIGIN}" "${TESTIMAGE}" ) ; then echo "Failed to prepare private registry" - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v docker network rm "${REGISTRY_NETWORK}" exit 1 fi @@ -127,7 +127,7 @@ if ! ( "${CONTEXT}"/run-k3s.sh "${K3S_CLUSTER_NAME}" \ "${K3S_KUBECONFIG}" "${TESTIMAGE}" ) ; then FAIL=true fi -docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v +docker compose -f "${DOCKER_COMPOSE_YAML}" down -v k3d cluster delete "${K3S_CLUSTER_NAME}" docker network rm "${REGISTRY_NETWORK}" diff --git a/script/kind/test.sh b/script/kind/test.sh index b0212ffd7..98b5b4046 100755 --- a/script/kind/test.sh +++ b/script/kind/test.sh @@ -103,11 +103,11 @@ EOF cp "${REPO}/script/kind/mirror.sh" "${MIRROR_TMP}/mirror.sh" if ! ( cd "${CONTEXT}" && \ docker network create "${REGISTRY_NETWORK}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ + docker compose -f "${DOCKER_COMPOSE_YAML}" up -d --force-recreate && \ docker exec "${PREPARE_NODE_NAME}" /bin/bash /tools/mirror.sh \ "${TESTIMAGE_ORIGIN}" "${TESTIMAGE}" ) ; then echo "Failed to prepare private registry" - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v docker network rm "${REGISTRY_NETWORK}" exit 1 fi @@ -127,7 +127,7 @@ if ! ( "${CONTEXT}"/run-kind.sh "${KIND_CLUSTER_NAME}" \ "${KIND_KUBECONFIG}" "${TESTIMAGE}" ) ; then FAIL=true fi -docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v +docker compose -f "${DOCKER_COMPOSE_YAML}" down -v kind delete cluster --name "${KIND_CLUSTER_NAME}" docker network rm "${REGISTRY_NETWORK}" diff --git a/script/optimize/test.sh b/script/optimize/test.sh index 8c0ae0698..92e767f3d 100755 --- a/script/optimize/test.sh +++ b/script/optimize/test.sh @@ -150,11 +150,11 @@ volumes: EOF local FAIL= if ! ( cd "${CONTEXT}" && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} testenv_opt && \ - docker-compose -f "${DOCKER_COMPOSE_YAML}" up --abort-on-container-exit ) ; then + docker compose -f "${DOCKER_COMPOSE_YAML}" build ${DOCKER_BUILD_ARGS:-} testenv_opt && \ + docker compose -f "${DOCKER_COMPOSE_YAML}" up --abort-on-container-exit ) ; then FAIL=true fi - docker-compose -f "${DOCKER_COMPOSE_YAML}" down -v + docker compose -f "${DOCKER_COMPOSE_YAML}" down -v if [ "${FAIL}" == "true" ] ; then exit 1 fi