Thursday, June 17, 2021

Upload my chia stats to the cloud baby

DATE=`/usr/bin/date`
echo $DATE >> /var/log/chia.status.upload.log
/root/bin/chia.status.up.exp

Which runs the following expect script


 root@ms2:~/bin# cat chia.status.up.exp
#!/usr/bin/expect -f
set timeout -1
spawn $env(SHELL)
match_max 100000
send -- "scp -P 2233 /var/log/chia.status.html uscopley@barilin.com:/home/uscopley/public_html/vpls/"
expect -exact "scp -P 2233 /var/log/chia.status.html uscopley@barilin.com:/home/uscopley/public_html/vpls/"
send -- "r"
expect -exact "d: "
send -- "XXXXXX"
expect -exact "#"
send -- "exitr"
expect eof
(venv) root@ms2:~/bin#

Add comment

Fill out the form below to add your own comments