mirror of
https://github.com/hassio-addons/addon-prometheus.git
synced 2025-05-04 11:11:24 +00:00
Following guidance in https://github.com/hassio-addons/addon-prometheus/pull/49#discussion_r926048521. Tested in local dev container.
12 lines
353 B
Text
Executable file
12 lines
353 B
Text
Executable file
#!/command/with-contenv bashio
|
|
bashio::log.info 'Starting prometheus config generator...'
|
|
|
|
if ! bashio::fs.directory_exists /share/prometheus/targets; then
|
|
mkdir -p /share/prometheus/targets
|
|
fi
|
|
|
|
cd /opt/prometheus-configgen || bashio::exit.nok \
|
|
"Could not change working directory for prometheus-configgen."
|
|
|
|
# Run Prometheus
|
|
exec python3 combiner
|