#!/bin/bash
set -e

DOCKER_IMAGE=registry.gitlab.com/euphon/themblem:research-$(git rev-parse --short HEAD)
docker build --network=host -t $DOCKER_IMAGE .

docker push $DOCKER_IMAGE

kubectl -n emblem set image deployment/research research=$DOCKER_IMAGE
kubectl -n emblem rollout status deployment/research