Skip to content

Commit

Permalink
try to fix init failed
Browse files Browse the repository at this point in the history
  • Loading branch information
yourmoonlight committed Oct 25, 2023
1 parent fb1e1d3 commit 603a73c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/check_dev_deploy_status.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,14 @@ fi

# get container status
STATUS=$(docker inspect --format '{{.State.Status}}' $CONTAINER_ID)
CLEANED_MNEMONIC=$(echo ${{secrets.DEV_MNEMONIC_PHRASE}} | tr '\n' ' ')

if [ "$STATUS" != "running" ]; then
echo "Container $CONTAINER_ID is not running,trying to clean data and restart"
echo "Start cleaning the data."
rooch server clean -n dev
rm -rf ~/.rooch
rooch init -m ${{secrets.DEV_MNEMONIC_PHRASE}} --skip-password
rooch init -m $CLEANED_MNEMONIC --skip-password
docker start $CONTAINER_ID
if [ $? -eq 0 ]; then
echo "Container $CONTAINER_ID Successfully restarted."
Expand Down

0 comments on commit 603a73c

Please sign in to comment.