Skip to content

Commit 4863175

Browse files
authored
style: improve aio startup logs + silent ch stdout (#868)
Ref: HDX-1801 startup logs are like ``` Send OpenTelemetry data via: http/protobuf: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4318 gRPC: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317 Exporting data to ClickHouse: Endpoint: tcp://ch-server:9000?dial_timeout=10s Database: default Waiting for ClickHouse to be ready... ClickHouse is ready! Visit the HyperDX UI at http://localhost:8080 ```
1 parent 59ee6d2 commit 4863175

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

docker/hyperdx/entry.local.base.sh

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,29 +31,28 @@ export DEFAULT_SOURCES='[{"from":{"databaseName":"default","tableName":"otel_log
3131
echo "127.0.0.1 ch-server" >> /etc/hosts
3232
echo "127.0.0.1 db" >> /etc/hosts
3333

34-
echo "Visit the HyperDX UI at $FRONTEND_URL/search"
35-
echo ""
36-
echo "Send OpenTelemetry data via"
37-
echo "http/protobuf: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4318"
38-
echo "gRPC: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317"
3934
echo ""
35+
echo "Send OpenTelemetry data via:
36+
http/protobuf: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4318
37+
gRPC: OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317
38+
"
4039
echo "Exporting data to ClickHouse:
4140
Endpoint: $CLICKHOUSE_ENDPOINT
4241
Database: $HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE
4342
"
44-
echo ""
4543

4644
# Start Clickhouse Server
47-
/entrypoint.sh &
45+
/entrypoint.sh > /var/log/clickhouse.log 2>&1 &
4846

4947
# Start Mongo Server
5048
mongod --quiet --dbpath /data/db > /var/log/mongod.log 2>&1 &
5149

5250
# Wait for Clickhouse to be ready
5351
while ! curl -s "http://ch-server:8123" > /dev/null; do
54-
echo "Waiting for Clickhouse to be ready..."
52+
echo "Waiting for ClickHouse to be ready..."
5553
sleep 1
5654
done
55+
echo "ClickHouse is ready!"
5756

5857
# Start Otel Collector
5958
opampsupervisor --config /etc/otel/supervisor.yaml > /var/log/otel-collector.log 2>&1 &
@@ -67,6 +66,10 @@ npx concurrently \
6766
"node -r /app/api/node_modules/@hyperdx/node-opentelemetry/build/src/tracing /app/api/packages/api/build/tasks/index.js check-alerts" \
6867
> /var/log/app.log 2>&1 &
6968

69+
echo ""
70+
echo "Visit the HyperDX UI at $FRONTEND_URL"
71+
echo ""
72+
7073
# Wait for any process to exit
7174
wait -n
7275

docker/hyperdx/entry.prod.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export OPAMP_PORT=${HYPERDX_OPAMP_PORT:-4320}
77
# ⚠️ Do not change this value !!!!
88
export IS_LOCAL_APP_MODE="REQUIRED_AUTH"
99

10+
echo ""
1011
echo "Visit the HyperDX UI at $FRONTEND_URL"
1112
echo ""
1213

0 commit comments

Comments
 (0)