summaryrefslogtreecommitdiffstats
path: root/ci
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2017-01-05 09:53:56 -0600
committerNarinder Gupta <narinder.gupta@canonical.com>2017-01-06 16:27:21 -0600
commit512a3b283ff25cad16a36605c80df4742673690b (patch)
treedfbe5f74a6a026d89ceb232c9c60ee65157674f4 /ci
parent9a825022ab2c447c1c77fde86c3731d89d1626dd (diff)
modified to add cpu as host cpu for kvm machines.
Change-Id: Ia265021a79d5595748ec0b6b3e5988adbc3086b7 Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci')
-rwxr-xr-xci/00-maasdeploy.sh6
-rwxr-xr-xci/02-deploybundle.sh6
-rwxr-xr-xci/03-maasdeploy.sh8
-rwxr-xr-xci/deploy.sh4
4 files changed, 15 insertions, 9 deletions
diff --git a/ci/00-maasdeploy.sh b/ci/00-maasdeploy.sh
index 556b65ab..f87e2d3d 100755
--- a/ci/00-maasdeploy.sh
+++ b/ci/00-maasdeploy.sh
@@ -192,11 +192,11 @@ maas maas sshkeys new key="`cat $HOME/.ssh/id_rsa.pub`"
#adding compute and control nodes VM to MAAS for virtual deployment purpose.
if [ "$virtinstall" -eq 1 ]; then
# create two more VMs to do the deployment.
- sudo virt-install --connect qemu:///system --name node1-control --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node1-control
+ sudo virt-install --connect qemu:///system --name node1-control --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node1-control
- sudo virt-install --connect qemu:///system --name node2-compute --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node2-compute
+ sudo virt-install --connect qemu:///system --name node2-compute --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node2-compute
- sudo virt-install --connect qemu:///system --name node5-compute --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node5-compute
+ sudo virt-install --connect qemu:///system --name node5-compute --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node5-compute
node1controlmac=`grep "mac address" node1-control | head -1 | cut -d "'" -f 2`
node2computemac=`grep "mac address" node2-compute | head -1 | cut -d "'" -f 2`
diff --git a/ci/02-deploybundle.sh b/ci/02-deploybundle.sh
index 23107878..e34f3d70 100755
--- a/ci/02-deploybundle.sh
+++ b/ci/02-deploybundle.sh
@@ -53,6 +53,12 @@ check_status() {
#read the value from deployment.yaml
+PROFILE=maas
+MAAS_IP=$(grep " ip_address" deployment.yaml | cut -d ':' -f 2 | sed -e 's/ //')
+API_SERVERMAAS="http://$MAAS_IP/MAAS/"
+API_KEY=`sudo maas-region apikey --username=ubuntu`
+maas login $PROFILE $API_SERVERMAAS $API_KEY
+
if [[ "$opnfvmodel" = "openstack" ]]; then
if [ -e ./deployment.yaml ]; then
if [ -e ./deployconfig.yaml ]; then
diff --git a/ci/03-maasdeploy.sh b/ci/03-maasdeploy.sh
index 2c7a16a8..0a934c20 100755
--- a/ci/03-maasdeploy.sh
+++ b/ci/03-maasdeploy.sh
@@ -275,7 +275,7 @@ parse_yaml2() {
}
addnodes(){
- sudo virt-install --connect qemu:///system --name bootstrap --ram 2048 --vcpus 2 --video \
+ sudo virt-install --connect qemu:///system --name bootstrap --ram 4098 --cpu host --vcpus 2 --video \
cirrus --arch x86_64 --disk size=20,format=qcow2,bus=virtio,io=native,pool=default \
--network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole \
--vnc --print-xml | tee bootstrap
@@ -325,11 +325,11 @@ fi
#adding compute and control nodes VM to MAAS for virtual deployment purpose.
if [ "$virtinstall" -eq 1 ]; then
# create two more VMs to do the deployment.
- sudo virt-install --connect qemu:///system --name node1-control --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node1-control
+ sudo virt-install --connect qemu:///system --name node1-control --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node1-control
- sudo virt-install --connect qemu:///system --name node2-compute --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node2-compute
+ sudo virt-install --connect qemu:///system --name node2-compute --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node2-compute
- sudo virt-install --connect qemu:///system --name node5-compute --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node5-compute
+ sudo virt-install --connect qemu:///system --name node5-compute --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node5-compute
node1controlmac=`grep "mac address" node1-control | head -1 | cut -d '"' -f 2`
node2computemac=`grep "mac address" node2-compute | head -1 | cut -d '"' -f 2`
diff --git a/ci/deploy.sh b/ci/deploy.sh
index d99c53e3..9d24d2f8 100755
--- a/ci/deploy.sh
+++ b/ci/deploy.sh
@@ -81,9 +81,9 @@ createresource() {
nodeexist=`maas maas nodes list hostname=node3-control`
if [ $nodeexist != *node3* ]; then
- sudo virt-install --connect qemu:///system --name node3-control --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node3-control
+ sudo virt-install --connect qemu:///system --name node3-control --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node3-control
- sudo virt-install --connect qemu:///system --name node4-control --ram 8192 --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node4-control
+ sudo virt-install --connect qemu:///system --name node4-control --ram 8192 --cpu host --vcpus 4 --disk size=120,format=qcow2,bus=virtio,io=native,pool=default --network bridge=virbr0,model=virtio --network bridge=virbr0,model=virtio --boot network,hd,menu=off --noautoconsole --vnc --print-xml | tee node4-control
node3controlmac=`grep "mac address" node3-control | head -1 | cut -d "'" -f 2`
node4controlmac=`grep "mac address" node4-control | head -1 | cut -d "'" -f 2`