annotate master/bin/makeWorker.sh @ 57:ac1a20e627a9

from lukasz git repo 2020-05-26 (see ~/src/wecu), then editted, sac not quite working yet
author Henry S. Thompson <ht@markup.co.uk>
date Wed, 27 May 2020 20:54:34 +0000
parents c49b169339b1
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5
580221a17890 comment out a lot not needed for vmss
Henry S. Thompson <ht@markup.co.uk>
parents: 4
diff changeset
1 #!/bin/bash
3
be5de30147ab just barely
Henry S. Thompson <ht@markup.co.uk>
parents:
diff changeset
2 # Usage . makeWorker.sh name
5
580221a17890 comment out a lot not needed for vmss
Henry S. Thompson <ht@markup.co.uk>
parents: 4
diff changeset
3 # Misnamed -- it assumes you've already done
580221a17890 comment out a lot not needed for vmss
Henry S. Thompson <ht@markup.co.uk>
parents: 4
diff changeset
4 # az vm create -n [name] -g cc --image Debian --size Standard_...
3
be5de30147ab just barely
Henry S. Thompson <ht@markup.co.uk>
parents:
diff changeset
5 # Source this to get the worker name set to its IP address
14
c1c8275bd194 trying to make this work
Henry S. Thompson <ht@markup.co.uk>
parents: 5
diff changeset
6 set -e -o pipefail
3
be5de30147ab just barely
Henry S. Thompson <ht@markup.co.uk>
parents:
diff changeset
7 name=$1
be5de30147ab just barely
Henry S. Thompson <ht@markup.co.uk>
parents:
diff changeset
8 ip=$(az vm list-ip-addresses -g cc -n $name|egrep -o '"ipAddress": ".*"' | cut -f 2 -d ' ' | tr -d \")
4
56d8823c68e0 pretty much complete...
Henry S. Thompson <ht@markup.co.uk>
parents: 3
diff changeset
9 setupTemplate.sh $ip
55
c49b169339b1 use bindWorkerVars.sh
Henry S. Thompson <ht@markup.co.uk>
parents: 14
diff changeset
10 . bindWorkerVars.sh $name
c49b169339b1 use bindWorkerVars.sh
Henry S. Thompson <ht@markup.co.uk>
parents: 14
diff changeset
11