diff options
| author | kaotisk <kaotisk@arching-kaos.org> | 2022-11-02 02:51:19 +0200 | 
|---|---|---|
| committer | kaotisk <kaotisk@arching-kaos.org> | 2022-11-02 02:51:19 +0200 | 
| commit | 082177d774668ee925e43da0d741d8642d87f9ea (patch) | |
| tree | 5d7c770fa9b30439122b4179af9c0bf5b2adbe11 /bin | |
| parent | db3c53b069617c57f49985b7ad8e5a2f97d1f54d (diff) | |
| download | arching-kaos-tools-082177d774668ee925e43da0d741d8642d87f9ea.tar.gz arching-kaos-tools-082177d774668ee925e43da0d741d8642d87f9ea.tar.bz2 arching-kaos-tools-082177d774668ee925e43da0d741d8642d87f9ea.zip  | |
Adapting to 96ae225b2a179ec36fdb01eaf906fec096002a08 change
Diffstat (limited to 'bin')
| -rwxr-xr-x | bin/ipfs-check | 27 | 
1 files changed, 14 insertions, 13 deletions
diff --git a/bin/ipfs-check b/bin/ipfs-check index b891ea1..0e53599 100755 --- a/bin/ipfs-check +++ b/bin/ipfs-check @@ -1,48 +1,49 @@  #!/bin/bash +PROGRAM="$(basename $0)"  logit(){ -	logthis "ipfs-check: $1" +	logthis "<$PROGRAM>" "$1" "$2"  }  ipfs files ls /zarchive > /dev/null  if [ $? != 0 ]  then -	logit "/zarchive is missing"  +	logit "[ERROR]" "/zarchive is missing"   else  -	logit "/zarchive OK" +	logit "[INFO]" "/zarchive OK"  fi  ipfs files ls /zlatest > /dev/null  if [ $? != 0 ]  then -	logit "/zlatest is missing"  +	logit "[ERROR]" "/zlatest is missing"   else -	logit "/zlatest is OK" +	logit "[INFO]" "/zlatest is OK"  fi  ipfs key list | grep zchain > /dev/null  if [ $? != 0 ]; then -	logit "zchain key is missing"  +	logit "[WARNING]" "zchain key is missing"   	ipfs key gen zchain > $ZCHAIN  	if [ $? != 0 ]; then -		logit "zchain fails to create" +		logit "[ERROR]" "zchain fails to create"  	else -		logit "zchain created" +		logit "[INFO]" "zchain created"  	fi  else -	logit "zchain is there" +	logit "[INFO]" "zchain is there"  fi  ipfs key list | grep ak-config > /dev/null  if [ $? != 0 ]; then -       	logit "ak-config key is missing"  +       	logit "[WARNING]" "ak-config key is missing"   	ipfs key gen ak-config  	if [ $? != 0 ]; then -		logit "ak-config fails to create" +		logit "[ERROR]" "ak-config fails to create"  	else -		logit "ak-config created" +		logit "[INFO]" "ak-config created"  	fi  else -	logit "ak-config is there" +	logit "[INFO]" "ak-config is there"  fi  | 
