Juju (software)

Juju is an open source application modeling tool developed by Canonical Ltd. Juju focuses on reducing the operation overhead of today's software by facilitating quickly deploying, configuring, scaling, integrating, and performing operational tasks on a wide choice of public and private cloud services along with bare metal servers and local container based deployments.

Juju
Original author(s)Canonical
Initial release2011[1]
Stable release
2.8.1 / July 13, 2020 (2020-07-13)[2]
Written inGo
Operating systemUbuntu, CentOS, MacOS
TypeOrchestration
LicenseGNU Affero GPL v3 LGPL
Websitejaas.ai

Juju modeling complex software topologies

Juju's mission is to provide a modeling language for users that abstracts the specifics of operating complex big software topologies. Doing so reduces the cost of operations and provides flexibility. A Juju Model is an environment to manage and operate a set of software applications. Models can be operated on many clouds: Amazon Web Services, Microsoft Azure, Google Compute Engine, OpenStack, etc. A Juju Controller is the service that tracks the events, state, and user activity across multiple models. You can think of it a bit like a database server where the controller is the server and models are different databases available on that server. Each model can have different configuration, sets of operating software, and different users with access at various levels. Some examples of models could be a web application, load balancer, and database in a "web-app" model. By using models deployments can be isolated into logical solutions and managed separately.

Juju can also be used to operate software on bare-metal servers by using Canonical's Metal as a Service, in containers using LXD, and more. Juju models provide an abstraction with allows the operations know-how to be cloud agnostic. This means that Charms and Bundles can help operate the same software with the same tooling on a public cloud, private cloud, or a local laptop.

Juju charms

The central mechanism behind Juju is called Charms. Charms can be written in any programming language that can be executed from the command line. A Charm is a collection of YAML configuration files and a selection of "hooks". A hook is a naming convention to install software, start/stop a service, manage relationships with other charms, upgrade charms, scale charms, configure charms, etc. Charms can have many properties. Charm helpers allow boiler-plate code to be automatically generated hence accelerating the creation of charms.

Juju client and environments

Juju has two components: a client and a bootstrap node. Currently clients exist for Ubuntu, CentOS, Mac and Windows. After installing the client, one or more environments can be bootstrapped. Juju environments can be bootstrapped on many clouds: Amazon Web Services, HP Cloud Services, Microsoft Azure, OpenStack, etc. By creating a Juju Provider, additional cloud environments can be supported. Juju can also be bootstrapped on bare-metal servers. Large deployments can use Canonical's Metal as a Service. Small deployments can use the manual provider, which allows any SSH Ubuntu machine to be converted into a Juju-managed machine. Juju can also be installed on a local Ubuntu machine via LXC operating system–level virtualization and the local provider.

Command line and GUI

Juju has both a command line and a GUI. The GUI allows users to visually see what software is currently running in which models in a very clear fashion. It also gives the user the power to search the Charmstore and browse results with detailed Charm information presented. It also allows the deployment of complex software stacks via drag-and-drop. The Juju GUI is automatically available on every controller.

Bundles

Juju also has a concept of Bundles. A Bundle is a portable specification for a model with charms, configuration, and relations all specified in a declarative YAML format. A Bundle YAML file can later be imported into another Juju model and shared with others. Bundles can also be uploaded to the charm store, allowing anybody to deploy a bundle via drag-and-drop or one command. In this example bundle, two applications are modeled; mediawiki, and mysql. Users can modify attributes declared in the bundle to customize their deployment:

services:
  mediawiki:
    charm: cs:trusty/mediawiki-3
    num_units: 1
    options:
      debug: false
      name: Please set name of wiki
      skin: vector
  mysql:
    charm: cs:trusty/mysql-29
    num_units: 1
    options:
      binlog-format: MIXED
      dataset-size: 80%
      tuning-level: safest
series: trusty
relations:
- - mediawiki:db
  - mysql:db

Charm Store

The Juju Charm Store launched on April 3, 2012.[3] The Charm Store regularly tests charms to notify charm authors when code breaks in addition to ensuring that Juju users have access to the latest versions of charms.

Supported platforms

Juju is available on Ubuntu server, with agents available for Ubuntu, CentOS[4] and Microsoft Windows.[5] Support for both CentOS and Windows has been contributed by Cloudbase Solutions.

gollark: Surely you can just pull a particular tag of the container.
gollark: I can come up with a thing to transmit ubqmachine™ details to osmarks.net or whatever which people can embed in their code.
gollark: It's an x86-64 system using debian or something.
gollark: > `import hashlib`Hashlib is still important!> `for entry, ubq323 in {**globals(), **__builtins__, **sys.__dict__, **locals(), CONSTANT: Entry()}.items():`Iterate over a bunch of things. I think only the builtins and globals are actually used.The stuff under here using `blake2s` stuff is actually written to be ridiculously unportable, to hinder analysis. This caused issues when trying to run it, so I had to hackily patch in the `/local` thing a few minutes before the deadline.> `for PyObject in gc.get_objects():`When I found out that you could iterate over all objects ever, this had to be incorporated somehow. This actually just looks for some random `os` function, and when it finds it loads the obfuscated code.> `F, G, H, I = typing(lookup[7]), typing(lookup[8]), __import__("functools"), lambda h, i, *a: F(G(h, i))`This is just a convoluted way to define `enumerate(range))` in one nice function.> `print(len(lookup), lookup[3], typing(lookup[3])) #`This is what actually loads the obfuscated stuff. I think.> `class int(typing(lookup[0])):`Here we subclass `complex`. `complex` is used for 2D coordinates within the thing, so I added some helper methods, such as `__iter__`, allowing unpacking of complex numbers into real and imaginary parts, `abs`, which generates a complex number a+ai, and `ℝ`, which provvides the floored real parts of two things.> `class Mаtrix:`This is where the magic happens. It actually uses unicode homoglyphs again, for purposes.> `self = typing("dab7d4733079c8be454e64192ce9d20a91571da25fc443249fc0be859b227e5d")`> `rows = gc`I forgot what exactly the `typing` call is looking up, but these aren't used for anything but making the fake type annotations work.> `def __init__(rows: self, self: rows):`This slightly nonidiomatic function simply initializes the matrix's internals from the 2D array used for inputs.> `if 1 > (typing(lookup[1]) in dir(self)):`A convoluted way to get whether something has `__iter__` or not.
gollark: If you guess randomly the chance of getting none right is 35%ish.

References

  1. Haslam, Marcus (3 November 2011). "Juju: a logo with a story". Ubuntu Blog.
  2. "Releases - juju/juju". Retrieved 4 June 2020 via GitHub.
  3. Castro, Jorge O. (April 3, 2012). "Why the juju charm store will change the way you use Ubuntu Server". Jorge's Stompbox. Retrieved September 1, 2012.
  4. "Juju CentOS support patches".
  5. "Juju Windows support patches".
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.