bridgehead/common/exporter-setup.sh

9 lines
669 B
Bash
Raw Normal View History

2023-09-04 16:43:40 +02:00
#!/bin/bash -e
2023-02-13 15:29:45 +01:00
2023-08-03 15:58:19 +02:00
if [ "$ENABLE_EXPORTER" == true ]; then
2023-02-14 10:20:19 +01:00
log INFO "Exporter setup detected -- will start Exporter service."
OVERRIDE+=" -f ./common/exporter-compose.yml"
EXPORTER_DB_PASSWORD="$(echo \"This is a salt string to generate one consistent password for the exporter. It is not required to be secret.\" | sha1sum | openssl pkeyutl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 30)"
EXPORTER_API_KEY="$(echo \"This is a salt string to generate one consistent API KEY for the exporter. It is not required to be secret.\" | sha1sum | openssl pkeyutl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 64)"
2023-02-14 10:20:19 +01:00
fi