From 67c937418e354a31df87ef60ebcc688617fd9cc6 Mon Sep 17 00:00:00 2001 From: Abdul Rabbani Date: Tue, 14 Jun 2022 09:06:51 -0400 Subject: [PATCH] Improve entrypoint to be more helpful --- entrypoint.sh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index 13da8da..70858ac 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -3,17 +3,21 @@ sleep 10 echo "Starting ipld-eth-beacon-indexer" -echo /root/ipld-eth-beacon-indexer capture ${CAPTURE_MODE} --config /root/ipld-eth-beacon-config.json +echo /root/ipld-eth-beacon-indexer capture ${CAPTURE_MODE} --config /root/ipld-eth-beacon-config.json > /root/ipld-eth-beacon-indexer.output -/root/ipld-eth-beacon-indexer capture ${CAPTURE_MODE} --config /root/ipld-eth-beacon-config.json +/root/ipld-eth-beacon-indexer capture ${CAPTURE_MODE} --config /root/ipld-eth-beacon-config.json > /root/ipld-eth-beacon-indexer.output rv=$? if [ $rv != 0 ]; then - echo "ipld-eth-beacon-indexer startup failed" - echo 1 > /root/HEALTH + echo "ipld-eth-beacon-indexer failed" + echo $rv > /root/HEALTH + echo $rv + cat /root/ipld-eth-beacon-indexer.output else - echo "ipld-eth-beacon-indexer startup succeeded" - echo 0 > /root/HEALTH + echo "ipld-eth-beacon-indexer succeeded" + echo $rv > /root/HEALTH + echo $rv + cat /root/ipld-eth-beacon-indexer.output fi tail -f /dev/null \ No newline at end of file