forked from axiom-team/astrXbian
Compare commits
2 Commits
0a12355376
...
af51349bba
Author | SHA1 | Date |
---|---|---|
fred | af51349bba | |
fred | 80de5613a6 |
|
@ -15,7 +15,7 @@ define('XZUID', $xzuid[0]);
|
|||
exec("/bin/bash -c './get_ipfs_node_id.sh'", $output);
|
||||
if (isset($output)) {
|
||||
|
||||
define('IPFS_NODE_ID', $output[0]);
|
||||
define('IPFS_NODE_ID', $output[0]);
|
||||
}
|
||||
|
||||
define('IPFS_API_PORT', 5001);
|
||||
|
@ -41,9 +41,11 @@ default 120x 90 Large Preview
|
|||
define('YOUTUBE_THUMB', 'https://i.ytimg.com/vi/%s/mqdefault.jpg');
|
||||
define ('MEDIAQR','https://'.$_SERVER['SERVER_NAME'].'/ipns/%s/QR.png');
|
||||
|
||||
|
||||
// TODO : dynamic finding FRIENDS xzuid with "cat /home/$YOU/.zen/ipfs_swarm/.*/_xbian.zuid"
|
||||
$stations = [
|
||||
'virgo',
|
||||
'onelove',
|
||||
'Rea-3E',
|
||||
'foot1060'
|
||||
'virgo',
|
||||
'onelove',
|
||||
'Rea-3E',
|
||||
'foot1060'
|
||||
];
|
||||
|
|
|
@ -69,7 +69,7 @@ do
|
|||
[[ -f ~/.zen/ipfs/.${IPFSNODEID}/KEY/${mediakey}/.timestamp ]] && TIMESTAMP=$(cat ~/.zen/ipfs/.${IPFSNODEID}/KEY/${mediakey}/.timestamp) # LAST REFRESH
|
||||
timestamp=$(date -u +%s%N | cut -b1-13)
|
||||
STAMPDIFF=$((timestamp - TIMESTAMP))
|
||||
echo "Last Update : $(date -d @$TIMESTAMP)"
|
||||
echo "Last Update : $(date -d @$TIMESTAMP | cut -b1-10)" # remove millisecond part
|
||||
echo "${mediakey} LAST UPDATED $STAMPDIFF milliseconds AGO"
|
||||
[ $STAMPDIFF -lt 21600000 ] && continue # 6h = 21600000 ms , 10h = 36000000 ms
|
||||
|
||||
|
@ -229,7 +229,7 @@ for ipnslink in $(ls ~/.zen/PIN/*/IPNSLINK 2>/dev/null | shuf ); do
|
|||
[[ ! $TIMESTAMP ]] && TIMESTAMP=$(cat /tmp/${mediakey}/*/.timestamp 2>/dev/null | tail -n 1 ) # INITIAL TIMESTAMP
|
||||
timestamp=$(date -u +%s%N | cut -b1-13)
|
||||
STAMPDIFF=$((timestamp - TIMESTAMP))
|
||||
echo "Last Update : $(date -d @$TIMESTAMP)"
|
||||
echo "Last Update : $(date -d @$TIMESTAMP | cut -b1-10)" # remove millisecond part
|
||||
echo "PIN WAS LAST UPDATED $STAMPDIFF milliseconds AGO"
|
||||
[ $STAMPDIFF -lt 39600000 ] && continue # 11h = 39600000 ms / 12h = 43200000 ms
|
||||
|
||||
|
|
Loading…
Reference in New Issue