#!/bin/bash
# Build, tag, and push vehicle discovery docker image to our registry
#
# Usage: ./build_bandwidth_estimation_responder_docker_image.sh <tag>
#
# If you don't provide an argument, tag will default to latest
# By convention, we use the current date as the tag, ex: 20180820

set -euo pipefail

tag=${1:-latest}

# Find workspace and set up env
workspace=$(bazel info workspace)
cd ${workspace}
source "$workspace/scripts/shell/bazel/function.sh"

echo "Building bandwidth_estimation_responder image: $tag"
bazel_run //teleop/ziod/bandwidth_estimation:push_bandwidth_estimation_responder_image --define bandwidth_estimation_responder_image_tag=$tag
