~hp-moonshot/ubuntu/trusty/hp-moonshot/hp-proliant

« back to all changes in this revision

Viewing changes to debian/hp-proliant/usr/bin/hp-proliant-bootstrap-juju

  • Committer: Narinder Gupta
  • Date: 2014-09-04 20:37:03 UTC
  • Revision ID: narinder.gupta@canonical.com-20140904203703-2sk67uwbzk9fc4tk
branch a new version for HP proliant systems where there is no power management required.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/sh
 
2
#
 
3
#    hp-proliant-bootstrap-juju - bootstrap Juju to one vm
 
4
#    Copyright (C) 2014 Canonical Ltd.
 
5
#
 
6
#    Authors: Dustin Kirkland <kirkland@canonical.com>
 
7
#             Kent Baxley <kent.baxley@canonical.com>
 
8
#    This program is free software: you can redistribute it and/or modify
 
9
#    it under the terms of the GNU General Public License as published by
 
10
#    the Free Software Foundation, version 3 of the License.
 
11
#
 
12
#    This program is distributed in the hope that it will be useful,
 
13
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
15
#    GNU General Public License for more details.
 
16
#
 
17
#    You should have received a copy of the GNU General Public License
 
18
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
19
 
 
20
set -x
 
21
 
 
22
. /etc/environment
 
23
 
 
24
juju status && echo "Existing deployment found, exiting." && exit 0
 
25
juju bootstrap --constraints "tags=bootstrap" --show-log --upload-tools
 
26
 
 
27
#accept the nodes which all already declared
 
28
#commission the other hardware nodes
 
29
maas admin nodes accept-all
 
30
 
 
31
juju set-constraints "tags="
 
32
 
 
33
#deploy juju-gui 
 
34
juju deploy --to 0 cs:~hazmat/trusty/juju-gui-2 juju-gui
 
35
juju expose juju-gui
 
36
 
 
37
#copy the bundle to the maas server for future deployment
 
38
 
 
39
bzr branch lp:~hp-proliant/charms/bundles/web-in-a-box/bundle /home/ubuntu/web-in-a-box
 
40
 
 
41
#display the ip address of the juju-gui
 
42
juju_address=$(nslookup moonshotvm.maas |  grep "Address: " | cut -d " " -f2)
 
43
echo "JUJU GUI details: name: moonshotvm.maas IP Address:" $juju_address
 
44