Skip to content

Instantly share code, notes, and snippets.

@thanhson1085
Last active March 22, 2019 02:55
Show Gist options
  • Select an option

  • Save thanhson1085/e2654432b8b2fcf43cacd5b2e8512ab6 to your computer and use it in GitHub Desktop.

Select an option

Save thanhson1085/e2654432b8b2fcf43cacd5b2e8512ab6 to your computer and use it in GitHub Desktop.
#!/bin/bash
# get tomochain container id
container_id=$(docker ps -q -f "name=tomochain")
cur_date=$(date +%Y-%m-%d)
# remove all peers
echo "\n----------------Save logs to /tmn/tomochain-${cur_date}.log----------------\n"
docker logs $container_id &> /tmp/tomochain-${cur_date}.log
@thanhson1085
Copy link
Author

curl https://gist.githubusercontent.com/thanhson1085/e2654432b8b2fcf43cacd5b2e8512ab6/raw/1900002420c00106f0e8a7a1b41cb3cf3052d00d/get-logs-tomochain.sh | bash

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment