storj/scripts/fix-mock-overlay
Matt Robinson 75c64035a2 Normalize the Docker Bits (#325)
* Normalize the dockerfiles and entrypoints

* fix formattting and docker-compose file

* add missing env var to satellite dockerfile

* Remove build args no longer in use

* More changes to make it all work
2018-09-07 15:46:08 -04:00

13 lines
362 B
Bash
Executable File

#!/bin/bash
set -euo pipefail
ids="$(
for cid in $(docker ps -a | awk '/storagenode/{print $1}'); do
ip="$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $cid)"
id="$(docker logs $cid 2>&1 | awk '/started/{print $5; exit}')"
echo $id:$ip:7777
done | tr '\n' ','
)"
sed -i'' -e "s/NODES=.*$/NODES=${ids%,}/" docker-compose.yaml