# this script expects $DOTOKEN variable with your digital ocean token # this script gets or creates smallest DO droplet and remotely executes script on it # afterwards, droplet is destroyed DROPLETNAME=example.com DOHOME="https://api.digitalocean.com/v2" cat < .curlargs -s -H "Authorization: Bearer $DOTOKEN" -H "Content-Type: application/json" EOF CURL="curl -K .curlargs" SSHKEYS=`$CURL "$DOHOME/account/keys" | R path ssh_keys | R map path fingerprint` CREATECONTAINER=`cat <