mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-10-27 05:52:29 +08:00
13 lines
670 B
Bash
Executable File
13 lines
670 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Wait for Kafka to be ready
|
|
until /opt/bitnami/kafka/bin/kafka-topics.sh --list --bootstrap-server localhost:9092; do
|
|
echo "Waiting for Kafka to be ready..."
|
|
sleep 2
|
|
done
|
|
|
|
# Create topics
|
|
/opt/bitnami/kafka/bin/kafka-topics.sh --create --bootstrap-server localhost:9092 --replication-factor 1 --partitions 8 --topic latestMsgToRedis
|
|
/opt/bitnami/kafka/bin/kafka-topics.sh --create --bootstrap-server localhost:9092 --replication-factor 1 --partitions 8 --topic msgToPush
|
|
/opt/bitnami/kafka/bin/kafka-topics.sh --create --bootstrap-server localhost:9092 --replication-factor 1 --partitions 8 --topic offlineMsgToMongoMysql
|
|
|
|
echo "Topics created." |