Run kafka-clusterid script when pillar values are missing

Signed-off-by: reyesj2 <94730068+reyesj2@users.noreply.github.com>
This commit is contained in:
reyesj2
2024-04-11 15:38:03 -04:00
parent af53dcda1b
commit ca7253a589
2 changed files with 8 additions and 4 deletions

View File

@@ -1116,6 +1116,7 @@ generate_passwords(){
SOCSRVKEY=$(get_random_value 64)
IMPORTPASS=$(get_random_value)
KAFKACLUSTERID=$(get_random_value 22)
KAFKAPASS=$(get_random_value)
}
generate_interface_vars() {
@@ -1947,7 +1948,8 @@ secrets_pillar(){
"secrets:"\
" import_pass: $IMPORTPASS"\
" influx_pass: $INFLUXPASS"\
" kafka_cluster_id: $KAFKACLUSTERID" > $local_salt_dir/pillar/secrets.sls
" kafka_cluster_id: $KAFKACLUSTERID"\
" kafka_pass: $KAFKAPASS" > $local_salt_dir/pillar/secrets.sls
fi
}