<commit_before><!--
Operation.md
Copyright 2013 Canonical Ltd.
This work is licensed under the Creative Commons Attribution-Share Alike 3.0
Unported License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative
Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.
-->

# Juju GUI Charm Operation #

## How it works ##

The Juju GUI is a client-side, JavaScript application that runs inside a web
browser. The browser connects to a single server deployed by the charm.

## Server ##


The server directly serves static files to the browser, including
images, HTML, CSS and JavaScript files via an HTTPS connection.

It also acts as a proxy between the browser and the Juju installation that
performs the actual deployment work. Both browser-server and server-Juju
connections are bidirectional via the WebSocket protocol, allowing changes
in the Juju installation to be propagated and shown immediately by the browser.



The GUI server is a custom-made application based on the
[Tornado](http://www.tornadoweb.org/) framework.

It directly serves static files to the browser, including images, HTML,
CSS and JavaScript files via an HTTPS connection.

It also acts as a proxy between the browser and the Juju installation that
performs the actual deployment work. Both browser-server and server-Juju
connections are bidirectional via the WebSocket protocol, allowing changes
in the Juju installation to be propagated and shown immediately by the browser.<commit_msg>Tweaks to the docs.<commit_after><!--
Operation.md
Copyright 2013 Canonical Ltd.
This work is licensed under the Creative Commons Attribution-Share Alike 3.0
Unported License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative
Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.
-->

# Juju GUI Charm Operation #

## How it works ##

The Juju GUI is a client-side, JavaScript application that runs inside a
web browser. The browser connects to a custom-made server deployed by
the charm.

## Server ##

The server directly serves static files to the browser, including
images, HTML, CSS and JavaScript files via an HTTPS connection to port
443. HTTP connections to the 80 port are redirected to the former one.
All other URLs serve the common `index.html` file.

It also acts as a proxy between the browser and the Juju API server that
performs the actual orchestration work. Both browser-server and server-
Juju connections are bidirectional, using the WebSocket protocol on the
same port as the HTTPS connection, allowing changes in the Juju
environment to be propagated and shown immediately by the browser.


[*** PACKAGE DOCSTRING STARTS HERE ***]

The GUI server is a custom-made application based on the
[Tornado](http://www.tornadoweb.org/) framework.

It directly serves static files to the browser, including
images, HTML, CSS and JavaScript files via an HTTPS connection to port
443. HTTP connections to the 80 port are redirected to the former one.
All other URLs serve the common `index.html` file.

It also acts as a proxy between the browser and the Juju API server that
performs the actual orchestration work. Both browser-server and server-
Juju connections are bidirectional, using the WebSocket protocol on the
same port as the HTTPS connection, allowing changes in the Juju
environment to be propagated and shown immediately by the browser.
{'fraction_non_alphanumeric': 0.05028571428571429, 'fraction_numerical': 0.013714285714285714, 'mean_word_length': 4.513385826771653, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7407283', 'n_tokens_mistral': 940, 'n_tokens_neox': 851, 'n_words': 510}