yuxiqian commented on code in PR #3605:
URL: https://github.com/apache/flink-cdc/pull/3605#discussion_r1904949015


##########
tools/cdcup/cdcup.sh:
##########
@@ -0,0 +1,71 @@
+#!/usr/bin/env bash
+
+# Do not continue after error
+set -e
+
+display_help() {
+  echo "Usage: ./cdcup.sh { init | up | pipeline <yaml> | flink | stop | down 
| help }"
+  echo
+  echo "Commands:"
+  echo "    * init:"
+  echo "        Initialize a playground environment, and generate 
configuration files."
+  echo
+  echo "    * up:"
+  echo "        Start docker containers. This may take a while before database 
is ready."
+  echo
+  echo "    * pipeline <yaml>:"
+  echo "        Submit a YAML pipeline job."
+  echo
+  echo "    * flink:"
+  echo "        Print Flink Web dashboard URL."
+  echo
+  echo "    * stop:"
+  echo "        Stop all running playground containers."
+  echo
+  echo "    * down:"
+  echo "        Stop and remove containers, networks, and volumes."
+  echo
+  echo "    * help:"
+  echo "        Print this message."
+}
+
+if [ "$1" == 'init' ]; then
+  printf "🚩 Building bootstrap docker image...\n"
+  docker build -q -t cdcup/bootstrap .
+  rm -rf cdc && mkdir -p cdc
+  printf "🚩 Starting bootstrap wizard...\n"
+  docker run -it --rm -v "$(pwd)/cdc":/cdc cdcup/bootstrap
+  mv cdc/docker-compose.yaml ./docker-compose.yaml
+  mv cdc/pipeline-definition.yaml ./pipeline-definition.yaml
+elif [ "$1" == 'up' ]; then
+  printf "🚩 Starting playground...\n"
+  docker compose up -d
+  docker compose exec jobmanager bash -c 'rm -rf /opt/flink-cdc'
+  docker compose cp cdc jobmanager:/opt/flink-cdc
+elif [ "$1" == 'pipeline' ]; then
+  if [ -z "$2" ]; then
+    printf "Usage: ./cdcup.sh pipeline <pipeline-definition.yaml>\n"
+    exit 1
+  fi
+  printf "🚩 Submitting pipeline job...\n"
+  docker compose cp "$2" jobmanager:/opt/flink-cdc/pipeline-definition.yaml
+  startup_script="cd /opt/flink-cdc && ./bin/flink-cdc.sh 
./pipeline-definition.yaml --flink-home /opt/flink"
+  if test -f ./cdc/lib/hadoop-uber.jar; then
+      startup_script="$startup_script --jar lib/hadoop-uber.jar"
+  fi
+  if test -f ./cdc/lib/mysql-connector-java.jar; then
+      startup_script="$startup_script --jar lib/mysql-connector-java.jar"

Review Comment:
   Can't reproduce this... Could you please check if 
`tools/cdcup/cdc/lib/mysql-connector-java.jar` exists?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to