Skip to content

Commit

Permalink
chore(test): docker-compose -> docker compose
Browse files Browse the repository at this point in the history
  • Loading branch information
kikito committed Sep 12, 2024
1 parent 0ee1576 commit ee9d478
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
10 changes: 5 additions & 5 deletions kong-build-tools/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -362,8 +362,8 @@ setup-kong-source:
cp kong/.requirements kong/distribution/.requirements

test-kong: kong-test-container
docker-compose up -d
bash -c 'healthy=$$(docker-compose ps | grep healthy | wc -l); while [[ "$$(( $$healthy ))" != "3" ]]; do docker-compose ps && sleep 5; done'
docker compose up -d
bash -c 'healthy=$$(docker compose ps | grep healthy | wc -l); while [[ "$$(( $$healthy ))" != "3" ]]; do docker compose ps && sleep 5; done'
docker exec kong /kong/.ci/run_tests.sh && $(MAKE) update-cache-images

release-kong-docker-images: test
Expand Down Expand Up @@ -517,7 +517,7 @@ setup-tests: cleanup-tests
ifneq ($(RESTY_IMAGE_BASE),src)
KONG_TEST_IMAGE_NAME=$(KONG_TEST_IMAGE_NAME) \
KONG_TEST_CONTAINER_NAME=$(KONG_TEST_CONTAINER_NAME) \
docker-compose -f test/kong-tests-compose.yaml up -d
docker compose -f test/kong-tests-compose.yaml up -d
while ! curl localhost:8001; do \
echo "Waiting for Kong to be ready..."; \
sleep 5; \
Expand All @@ -526,8 +526,8 @@ endif

cleanup-tests:
ifneq ($(RESTY_IMAGE_BASE),src)
docker-compose -f test/kong-tests-compose.yaml down
docker-compose -f test/kong-tests-compose.yaml rm -f
docker compose -f test/kong-tests-compose.yaml down
docker compose -f test/kong-tests-compose.yaml rm -f
docker stop user-validation-tests || true
docker rm user-validation-tests || true
docker volume prune -f
Expand Down
10 changes: 5 additions & 5 deletions kong-build-tools/test/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ start_kong() {
if [ "$SSL_PROVIDER" = "boringssl" ]; then
KONG_FIPS=on
fi
KONG_FIPS=$KONG_FIPS KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker-compose -f "$TEST_COMPOSE_PATH" up -d
KONG_FIPS=$KONG_FIPS KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker compose -f "$TEST_COMPOSE_PATH" up -d
}

stop_kong() {
KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker-compose -f "$TEST_COMPOSE_PATH" down
KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker-compose -f "$TEST_COMPOSE_PATH" rm -f
KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker compose -f "$TEST_COMPOSE_PATH" down
KONG_TEST_IMAGE_NAME=${1:-$KONG_TEST_IMAGE_NAME} docker compose -f "$TEST_COMPOSE_PATH" rm -f
docker stop $(docker ps -a -q) || true
docker rm $(docker ps -a -q) || true
docker volume prune -f
Expand All @@ -75,8 +75,8 @@ kong_ready() {
wait_kong() {
while ! kong_ready; do
msg_test "Waiting for Kong to be ready "
docker-compose -f "$TEST_COMPOSE_PATH" ps
docker-compose -f "$TEST_COMPOSE_PATH" logs kong
docker compose -f "$TEST_COMPOSE_PATH" ps
docker compose -f "$TEST_COMPOSE_PATH" logs kong
sleep 5
done
}
Expand Down

0 comments on commit ee9d478

Please sign in to comment.