Fix up e2e test for update demo.

Use the scripts that are in the example directory.  Also actually run the update as part of the test.
This commit is contained in:
Joe Beda 2014-09-02 14:15:01 -07:00
parent 72d646a8a1
commit 354ee3666c
4 changed files with 17 additions and 5 deletions

View File

@ -19,6 +19,9 @@ if [ -z "$DOCKER_HUB_USER" ] ; then
exit 1
fi
export KUBE_REPO_ROOT=${KUBE_REPO_ROOT-$(dirname $0)/../..}
export KUBECFG=${KUBECFG-$KUBE_REPO_ROOT/cluster/kubecfg.sh}
set -x
../../cluster/kubecfg.sh -p 8080:80 run $DOCKER_HUB_USER/update-demo:nautilus 2 update-demo
$KUBECFG -p 8080:80 run $DOCKER_HUB_USER/update-demo:nautilus 2 update-demo

View File

@ -16,6 +16,9 @@
NEW_SIZE=${1:-4}
export KUBE_REPO_ROOT=${KUBE_REPO_ROOT-$(dirname $0)/../..}
export KUBECFG=${KUBECFG-$KUBE_REPO_ROOT/cluster/kubecfg.sh}
set -x
../../cluster/kubecfg.sh resize update-demo $NEW_SIZE
$KUBECFG resize update-demo $NEW_SIZE

View File

@ -20,7 +20,10 @@ if [ -z "$DOCKER_HUB_USER" ] ; then
fi
NEW_IMAGE=${1:-kitten}
TIMING=${2:-10s}
export KUBE_REPO_ROOT=${KUBE_REPO_ROOT-$(dirname $0)/../..}
export KUBECFG=${KUBECFG-$KUBE_REPO_ROOT/cluster/kubecfg.sh}
set -x
../../cluster/kubecfg.sh -image $DOCKER_HUB_USER/update-demo:$NEW_IMAGE -u 10s rollingupdate update-demo
$KUBECFG -image $DOCKER_HUB_USER/update-demo:$NEW_IMAGE -u $TIMING rollingupdate update-demo

View File

@ -14,7 +14,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.
export KUBE_REPO_ROOT=${KUBE_REPO_ROOT-$(dirname $0)/../..}
export KUBECFG=${KUBECFG-$KUBE_REPO_ROOT/cluster/kubecfg.sh}
set -x
../../cluster/kubecfg.sh stop update-demo
../../cluster/kubecfg.sh rm update-demo
$KUBECFG stop update-demo
$KUBECFG rm update-demo