Skip to content

Commit

Permalink
add support for docker compose v2 (fix #730) (#1140)
Browse files Browse the repository at this point in the history
* add support for docker compose v2 (fix #730)

Signed-off-by: uniform64 <jiny2048@gmail.com>

* add support for docker compose v2 (fix #730)
some missing places in the previous commit

Signed-off-by: uniform64 <jiny2048@gmail.com>

---------

Signed-off-by: uniform64 <jiny2048@gmail.com>
  • Loading branch information
uniform641 authored Dec 11, 2023
1 parent 07e7ee4 commit cdb126d
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 4 deletions.
6 changes: 5 additions & 1 deletion test-network/addOrg3/addOrg3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ export VERBOSE=false
. ../scripts/utils.sh

: ${CONTAINER_CLI:="docker"}
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
if command -v docker-compose > /dev/null 2>&1; then
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
else
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
fi
infoln "Using ${CONTAINER_CLI} and ${CONTAINER_CLI_COMPOSE}"


Expand Down
6 changes: 5 additions & 1 deletion test-network/network.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ trap "popd > /dev/null" EXIT
. scripts/utils.sh

: ${CONTAINER_CLI:="docker"}
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
if command -v docker-compose > /dev/null 2>&1; then
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
else
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
fi
infoln "Using ${CONTAINER_CLI} and ${CONTAINER_CLI_COMPOSE}"

# Obtain CONTAINER_IDS and remove them
Expand Down
6 changes: 5 additions & 1 deletion test-network/scripts/createChannel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ BFT="$5"
: ${BFT:=0}

: ${CONTAINER_CLI:="docker"}
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
if command -v docker-compose > /dev/null 2>&1; then
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
else
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
fi
infoln "Using ${CONTAINER_CLI} and ${CONTAINER_CLI_COMPOSE}"

if [ ! -d "channel-artifacts" ]; then
Expand Down
6 changes: 5 additions & 1 deletion test-network/scripts/deployCCAAS.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ VERBOSE=${12:-"false"}
CCAAS_SERVER_PORT=9999

: ${CONTAINER_CLI:="docker"}
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
if command -v docker-compose > /dev/null 2>&1; then
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
else
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
fi
infoln "Using ${CONTAINER_CLI} and ${CONTAINER_CLI_COMPOSE}"

println "executing with the following"
Expand Down

0 comments on commit cdb126d

Please sign in to comment.