2 # SPDX-license-identifier: Apache-2.0
3 ##############################################################################
5 # All rights reserved. This program and the accompanying materials
6 # are made available under the terms of the Apache License, Version 2.0
7 # which accompanies this distribution, and is available at
8 # http://www.apache.org/licenses/LICENSE-2.0
9 ##############################################################################
18 csar_id=6b54a728-b76a-11e8-a1ba-52540053ccc8
21 populate_CSAR_virtlet $csar_id
23 pushd ${CSAR_DIR}/${csar_id}
25 setup $virtlet_deployment_name
28 deployment_pod=$(kubectl get pods | grep $virtlet_deployment_name | awk '{print $1}')
29 vm_name=$(kubectl virt virsh list | grep "virtlet-.*-$virtlet_deployment_name" | awk '{print $2}')
30 vm_status=$(kubectl virt virsh list | grep "virtlet-.*-$virtlet_deployment_name" | awk '{print $3}')
31 if [[ "$vm_status" != "running" ]]; then
32 echo "There is no Virtual Machine running by $deployment_pod pod"
35 echo "Pod name: $deployment_pod Virsh domain: $vm_name"
36 echo "ssh testuser@$(kubectl get pods $deployment_pod -o jsonpath="{.status.podIP}")"
37 echo "kubectl attach -it $deployment_pod"
38 echo "=== Virtlet details ===="
39 echo "$(kubectl virt virsh dumpxml $vm_name | grep VIRTLET_)\n"
43 teardown $virtlet_deployment_name