This lesson will introduce you to Ubuntu Juju, an open-source service management tool.
Tip
Duration: 1 hour
In order to conduct this lesson you should have knowledge of
Ubuntu Juju is an open source configuration management tool to deploy and provision software on a virtualized environment. MySQL, RabbitMQ, OpenStack, WordPress, Apache, MediaWiki, MongoDB, Hadoop, and many other software are available on the Juju’s official repository, Juju Charm Store. Juju Charm is a structured bundle of files with metadata, configuration data and hooks with some extra support files to provision cloud software.
This lesson covers for:
Here we use a OpenStack VM instance to start Juju.
Note
If you need to know how to create a VM instance on FutureSystems, see here: Launching a New Instance
Once you are in a VM instance, refresh the package lists with the following commands:
sudo add-apt-repository ppa:juju/stable -y
sudo apt-get update
Install Juju packages:
sudo apt-get install juju-quickstart -y
sudo apt-get install juju-core -y
Try to use Homebrew for installing Juju on OSX:
brew install juju-quickstart
brew install juju
Download link for Windows 7, 8 (as of 03/31/2015): https://launchpad.net/juju-core/1.21/1.21.3/+download/juju-setup-1.21.3-signed.exe
Warning
The installation on Windows and OSX are not tested by our team.
juju-quickstart mediawiki-single
In this step, you choose your cloud provider. You can simply choose a local environment. Juju will deploy software inside of your VM instance.
juju-quickstart contains Juju GUI. You can use a web browser to manage your services on Juju.
Since Juju GUI is running with a virtual network in your VM instance, you need
to configure iptables
. Your Juju GUI will be served on your floating IP
address with the FORWARD rules.:
sudo iptables -t nat -A PREROUTING -p tcp -d 0.0.0.0 --dport 443 -j DNAT --to-destination [IP ADDRESS of Juju GUI]:443
You can find a IP address of your Juju GUI with the following command:
juju status
You may find public-address
under juju-gui
section:
...
services:
juju-gui:
charm: cs:trusty/juju-gui-22
exposed: true
units:
juju-gui/0:
agent-state: started
agent-state-info: (started)
agent-version: 1.22.0.1
machine: "1"
open-ports:
- 80/tcp
- 443/tcp
public-address: [IP ADDRESS]
...
To login Juju GUI, you need a username and a password.
When you start a service with juju-quickstart
, the username and the
password will be printed out on your screen. Use them to login.
An example of output:
...
Juju GUI URL: https://10.0.3.1
username: admin
password: adm-b908bcba211a1234ac73e732b6e3315d
...
Basic instructions and lessons in this page are adapted from the Juju website