Skip to content

Commit

Permalink
Merge pull request #1172 from ballerina-platform/TharmiganK-patch-1
Browse files Browse the repository at this point in the history
Update docker command to docker compose v2
  • Loading branch information
TharmiganK authored Aug 2, 2024
2 parents c58faee + 73abccc commit d1e8806
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions ballerina/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ task startKafkaServer() {
if (!stdOut.toString().contains("kafka-test")) {
println "Starting Kafka server."
exec {
commandLine 'sh', '-c', "docker-compose -f tests/docker-compose.yaml up -d"
commandLine 'sh', '-c', "docker compose -f tests/compose.yaml up -d"
standardOutput = stdOut
}
println stdOut.toString()
Expand All @@ -141,7 +141,7 @@ task stopKafkaServer() {
if (stdOut.toString().contains("kafka-test")) {
println "Stopping Kafka server."
exec {
commandLine 'sh', '-c', "docker-compose -f tests/docker-compose.yaml rm -svf"
commandLine 'sh', '-c', "docker compose -f tests/compose.yaml rm -svf"
standardOutput = stdOut
}
println stdOut.toString()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
version: '2'

services:
zookeeper-add-kafka-users:
image: 'confluentinc/cp-kafka:latest'
Expand Down
2 changes: 1 addition & 1 deletion examples/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ task stopKafkaServer() {
if (stdOut.toString().contains("kafka-test")) {
println "Stopping Kafka server."
exec {
commandLine 'sh', '-c', "docker-compose -f ../ballerina/tests/docker-compose.yaml rm -svf"
commandLine 'sh', '-c', "docker compose -f ../ballerina/tests/compose.yaml rm -svf"
standardOutput = stdOut
}
println stdOut.toString()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ The difference in this example is that, we use a secured kafka cluster and commu
2. [Use Kafka with docker](https://hub.docker.com/r/confluentinc/cp-kafka/)

* You can refer [here](https://docs.confluent.io/platform/current/kafka/authentication_ssl.html) to learn how to deploy a secured Kafka cluster.
* You can find the docker file used to set up the cluster for this example in [here](../../ballerina/tests/docker-compose.yaml).
* You can find the docker file used to set up the cluster for this example in [here](../../ballerina/tests/compose.yaml).

## Run the Example

Expand Down

0 comments on commit d1e8806

Please sign in to comment.