Merge lp:~frankban/charms/precise/juju-gui/use-env-name into lp:~juju-gui/charms/precise/juju-gui/trunk
Status: | Merged |
---|---|
Merged at revision: | 158 |
Proposed branch: | lp:~frankban/charms/precise/juju-gui/use-env-name |
Merge into: | lp:~juju-gui/charms/precise/juju-gui/trunk |
Diff against target: |
116 lines (+61/-6) 5 files modified
config.yaml (+2/-4) hooks/backend.py (+1/-1) hooks/utils.py (+29/-0) revision (+1/-1) tests/test_utils.py (+28/-0) |
To merge this branch: | bzr merge lp:~frankban/charms/precise/juju-gui/use-env-name |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
charmers | Pending | ||
Review via email:
|
Description of the change
Add jenv file path to the GUI login help text.
Change the GUI login message to give exact
jenv file to look in for the admin secret, if
the environment name is available in the hook's
context.
Tests: `make unittest`.
QA:
1) bootstrap a stable juju-core;
2) deploy this branch with `make deploy`;
3) open the GUI: the login message should point
you generically to the path where to find
the jenv files;
4) destroy the environment;
5) bootstrap juju-core trunk (at least revno 2289);
6) deploy this branch with `make deploy`;
7) open the GUI: the login message should point you
to the exact path to the jenv file;
8) now execute "juju set juju-gui login-help=HELP!",
and wait a couple of seconds;
9) open the GUI again and you should see the new message;
10) destroy the environment.
Done, thank you!
Reviewers: mp+204503_ code.launchpad. net,
Message:
Please take a look.
Description:
Add jenv file path to the GUI login help text.
Change the GUI login message to give exact
jenv file to look in for the admin secret, if
the environment name is available in the hook's
context.
Tests: `make unittest`.
QA:
1) bootstrap a stable juju-core;
2) deploy this branch with `make deploy`;
3) open the GUI: the login message should point
you generically to the path where to find
the jenv files;
4) destroy the environment;
5) bootstrap juju-core trunk (at least revno 2289);
6) deploy this branch with `make deploy`;
7) open the GUI: the login message should point you
to the exact path to the jenv file;
8) now execute "juju set juju-gui login-help=HELP!",
and wait a couple of seconds;
9) open the GUI again and you should see the new message;
10) destroy the environment.
Done, thank you!
https:/ /code.launchpad .net/~frankban/ charms/ precise/ juju-gui/ use-env- name/+merge/ 204503
(do not edit description out of merge proposal)
Please review this at https:/ /codereview. appspot. com/59560044/
Affected files (+50, -6 lines):
A [revision details]
M config.yaml
M hooks/backend.py
M hooks/utils.py
M revision
M tests/test_utils.py
Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision:
<email address hidden>
+New revision:
<email address hidden>
Index: config.yaml environments. yaml.
=== modified file 'config.yaml'
--- config.yaml 2014-01-16 19:25:52 +0000
+++ config.yaml 2014-02-03 14:02:24 +0000
@@ -74,11 +74,9 @@
type: string
login-help:
description: |
- The help text shown to the user on the login screen.
+ The help text shown to the user on the login screen. If not
provided, a
+ default message is used, suggesting how to find the login
credentials.
type: string
- default: |
- The password is the admin-secret from the Juju environment. This can
- often be found by looking in ~/.juju/
read-only:
description: |
Whether or not the GUI is in read-only mode. Note that read-only
mode is
Index: revision
=== modified file 'revision'
--- revision 2014-01-22 09:07:34 +0000
+++ revision 2014-02-03 14:02:24 +0000
@@ -1,1 +1,1 @@
-103
+104
Index: hooks/backend.py build_dir(
config[ 'juju-gui- debug'] , config[ 'serve- tests'] )
utils. write_gui_ config( 'juju-gui- console- enabled' ], config[ 'login- help'], 'juju-gui- console- enabled' ], config. get('login- help'),
config[ 'read-only' ], config[ 'charmworld- url'],
build_dir, secure= config[ 'secure' ], sandbox= config[ 'sandbox' ],
ga_key= config[ 'ga-key' ],
=== modified file 'hooks/backend.py'
--- hooks/backend.py 2014-01-28 11:01:55 +0000
+++ hooks/backend.py 2014-02-03 14:02:24 +0000
@@ -127,7 +127,7 @@
build_dir = utils.compute_
- config[
+ config[
Index: hooks/utils.py
=== modified file 'hooks/utils.py'
--- hooks/utils....