1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
#!/bin/bash tag="$1" if [[ ! $tag ]]; then echo "No tag specified." exit 1 fi snapshot="$2" if [[ ! $snapshot ]]; then echo "No snapshot file or URL specified." exit 1 fi docker build \ -t "astroconda/buildsys-pipeline:${tag}" \ --build-arg SNAPSHOT_INPUT="${snapshot}" $(pwd)