summaryrefslogtreecommitdiffstats
path: root/ci/02-maasdeploy.sh
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2016-05-16 12:16:00 -0500
committerNarinder Gupta <narinder.gupta@canonical.com>2016-05-17 14:25:14 -0500
commit943a83ac552121d599476661634d250a44be590b (patch)
treed66adc0c9e68e305fdf86d6a83c71b61a0e27ea3 /ci/02-maasdeploy.sh
parent7cfca76c31a05ddc4b124d9074fa13ae04929cdb (diff)
added new labconfig file for each lab also the default config file.
User can send the url also to deployment.yaml file to the script. If can not copy the file then will use the file from labconfig directory. Change-Id: I4edce4d291782462a483f6840b1de36b13174720 Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci/02-maasdeploy.sh')
-rwxr-xr-xci/02-maasdeploy.sh17
1 files changed, 13 insertions, 4 deletions
diff --git a/ci/02-maasdeploy.sh b/ci/02-maasdeploy.sh
index be978667..20357803 100755
--- a/ci/02-maasdeploy.sh
+++ b/ci/02-maasdeploy.sh
@@ -4,12 +4,17 @@ set -ex
virtinstall=0
+cp maas/deployment.yaml ./deployment.yaml
+cp ../labconfig/intel/pod6/labconfig.yaml ./
+
case "$1" in
'intelpod5' )
cp maas/intel/pod5/deployment.yaml ./deployment.yaml
;;
'intelpod6' )
- cp maas/intel/pod6/deployment.yaml ./deployment.yaml
+ cp ../labconfig/intel/pod6/labconfig.yaml ./
+ #to be removed later once converted for all labs.
+ python deploy.py
;;
'intelpod9' )
cp maas/intel/pod9/deployment.yaml ./deployment.yaml
@@ -39,9 +44,6 @@ case "$1" in
;;
esac
-#just make sure the ssh keys added into maas for the current user
-sed --i "s@/home/ubuntu@$HOME@g" ./deployment.yaml
-sed --i "s@qemu+ssh://ubuntu@qemu+ssh://$USER@g" ./deployment.yaml
#make sure no password asked during the deployment.
@@ -145,6 +147,13 @@ crnodevlanint() {
done
}
+#convert labconfig file to deployment.yaml to consume by MAAS.
+#python deploy.py
+
+#just make sure the ssh keys added into maas for the current user
+sed --i "s@/home/ubuntu@$HOME@g" ./deployment.yaml
+sed --i "s@qemu+ssh://ubuntu@qemu+ssh://$USER@g" ./deployment.yaml
+
sudo maas-deployer -c deployment.yaml -d --force
sudo chown $USER:$USER environments.yaml