Commit eba2fe40 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Updated deployment scripts

parent 269158bf
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -212,8 +212,8 @@ export GRAF_EXT_PORT_HTTP=${GRAF_EXT_PORT_HTTP:-"3000"}
# Deploy QuestDB
./deploy/qdb.sh

## Deploy Apache Kafka
#./deploy/kafka.sh
# Deploy Apache Kafka
./deploy/kafka.sh

# Expose Dashboard
./deploy/expose_dashboard.sh
+16 −16
Original line number Diff line number Diff line
@@ -112,16 +112,16 @@ export PROM_EXT_PORT_HTTP=${PROM_EXT_PORT_HTTP:-"9090"}
export GRAF_EXT_PORT_HTTP=${GRAF_EXT_PORT_HTTP:-"3000"}


## ----- Apache Kafka ------------------------------------------------------
#
## If not already set, set the namespace where Apache Kafka will be deployed.
#export KFK_NAMESPACE=${KFK_NAMESPACE:-"kafka"}
#
## If not already set, set the port Apache Kafka server will be exposed to.
#export KFK_SERVER_PORT=${KFK_SERVER_PORT:-"9092"}
#
## If not already set, if flag is YES, Apache Kafka will be redeployed and topic will be lost.
#export KFK_REDEPLOY=${KFK_REDEPLOY:-""}
# ----- Apache Kafka ------------------------------------------------------

# If not already set, set the namespace where Apache Kafka will be deployed.
export KFK_NAMESPACE=${KFK_NAMESPACE:-"kafka"}

# If not already set, set the port Apache Kafka server will be exposed to.
export KFK_SERVER_PORT=${KFK_SERVER_PORT:-"9092"}

# If not already set, if flag is YES, Apache Kafka will be redeployed and topic will be lost.
export KFK_REDEPLOY=${KFK_REDEPLOY:-""}

########################################################################################################################
# Automated steps start here
@@ -153,12 +153,12 @@ kubectl create secret generic crdb-data --namespace ${TFS_K8S_NAMESPACE} --type=
    --from-literal=CRDB_SSLMODE=require
printf "\n"

#echo ">>> Create Secret with Apache Kafka..."
#KFK_SERVER_PORT=$(kubectl --namespace ${KFK_NAMESPACE} get service kafka-service -o 'jsonpath={.spec.ports[0].port}')
#kubectl create secret generic kfk-kpi-data --namespace ${TFS_K8S_NAMESPACE} --type='Opaque' \
#    --from-literal=KFK_NAMESPACE=${KFK_NAMESPACE} \
#    --from-literal=KFK_SERVER_PORT=${KFK_SERVER_PORT}
#printf "\n"
echo ">>> Create Secret with Apache Kafka..."
KFK_SERVER_PORT=$(kubectl --namespace ${KFK_NAMESPACE} get service kafka-service -o 'jsonpath={.spec.ports[0].port}')
kubectl create secret generic kfk-kpi-data --namespace ${TFS_K8S_NAMESPACE} --type='Opaque' \
    --from-literal=KFK_NAMESPACE=${KFK_NAMESPACE} \
    --from-literal=KFK_SERVER_PORT=${KFK_SERVER_PORT}
printf "\n"

echo "Create secret with NATS data"
NATS_CLIENT_PORT=$(kubectl --namespace ${NATS_NAMESPACE} get service ${NATS_NAMESPACE} -o 'jsonpath={.spec.ports[?(@.name=="client")].port}')
+19 −1
Original line number Diff line number Diff line
@@ -22,7 +22,25 @@ kubectl delete namespace kafka --ignore-not-found
printf "\n"

echo "Deployting TeraFlowSDN..."
./deploy/all.sh

# Deploy CockroachDB
./deploy/crdb.sh

# Deploy NATS
./deploy/nats.sh

# Deploy QuestDB
./deploy/qdb.sh

# Expose Dashboard
./deploy/expose_dashboard.sh

# Deploy TeraFlowSDN
./deploy/tfs.sh

# Show deploy summary
./deploy/show.sh

printf "\n"

echo "Waiting for Context to be subscribed to NATS..."