You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
633 B
Bash
22 lines
633 B
Bash
#!/usr/bin/env bash
|
|
|
|
if [ ! -d go ]; then
|
|
echo "[!] Creating go output directory"
|
|
mkdir go;
|
|
fi
|
|
|
|
echo "[+] Building docker container"
|
|
docker image build -t go-iperf-builder:1.0 .
|
|
docker container run --detach --name builder go-iperf-builder:1.0
|
|
docker cp grpc:/go/src/github.com/BGrewell/go-iperf/api/go/api.pb.go go/.
|
|
echo "[+] Updating of go library complete"
|
|
|
|
echo "[+] Removing docker container"
|
|
docker rm builder
|
|
|
|
echo "[+] Adding new files to source control"
|
|
git add go/api.pb.go
|
|
git commit -m "regenerated grpc libraries"
|
|
git push
|
|
|
|
echo "[+] Done. Everything has been rebuilt and the repository has been updated and pushed" |