Log warning when running without metrics support

This commit is contained in:
Jacek Sieka 2020-12-10 11:59:31 +01:00 committed by zah
parent 92750d5313
commit bc977799f6
1 changed files with 4 additions and 2 deletions

View File

@ -1319,12 +1319,14 @@ programMain:
config.createDumpDirs()
when useInsecureFeatures:
if config.metricsEnabled:
if config.metricsEnabled:
when useInsecureFeatures:
let metricsAddress = config.metricsAddress
notice "Starting metrics HTTP server",
url = "http://" & $metricsAddress & ":" & $config.metricsPort & "/metrics"
metrics.startHttpServer($metricsAddress, config.metricsPort)
else:
warn "Metrics support disabled, see https://status-im.github.io/nimbus-eth2/metrics-pretty-pictures.html#simple-metrics"
if depositContractAddress.isNone or depositContractDeployedAt.isNone:
echo "Please specify the a network through the --network option"