kuryr-kubernetes/contrib/regenerate_controller_pod.sh
Daniel Mellado 6f097561e5 Add regenerate controller pod script
When developing using containerized mode, you'd need to go over the
steps on [1] quite a few times. This script just automates the process
for ease of development.

[1] https://docs.openstack.org/kuryr-kubernetes/latest/installation/devstack/containerized.html

Change-Id: I034b1d79941e1f986dd7c4991c7c971bb202bf75
2018-07-11 10:33:21 -04:00

18 lines
415 B
Bash
Executable File

#!/bin/bash
set -o errexit
KURYR_DIR=${KURYR_DIR:-/opt/stack/kuryr-kubernetes}
KURYR_CONTROLLER_NAME=${KURYR_CONTROLLER_NAME:-kuryr-controller}
function build_tagged_container {
docker build -t kuryr/controller -f $KURYR_DIR/controller.Dockerfile $KURYR_DIR
}
function recreate_controller {
kubectl delete pods -n kube-system -l name=$KURYR_CONTROLLER_NAME
}
build_tagged_container
recreate_controller