Merge ~kwmonroe/layer-leadership:master into layer-leadership:master

Proposed by Kevin W Monroe
Status: Merged
Merged at revision: 8846afcc42efe8a6ddd09c3122f2b0b43efdf3cc
Proposed branch: ~kwmonroe/layer-leadership:master
Merge into: layer-leadership:master
Diff against target: 48 lines (+0/-18)
1 file modified
dev/null (+0/-18)
Reviewer Review Type Date Requested Status
Stuart Bishop Approve
Review via email: mp+299986@code.launchpad.net

Description of the change

Remove the hooks from the leadership layer. These are now provided by layer:basic:

https://github.com/juju-solutions/layer-basic/tree/master/hooks

This is needed because the layer:leadership hooks are not up to date with layer:basic. They do not do "basic.init_config_states()", which causes "config.set.X" states to be removed after leader-elected runs.

To post a comment you must log in.
Revision history for this message
Stuart Bishop (stub) wrote :

Thanks for catching this. Looks good.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/hooks/leader-elected b/hooks/leader-elected
2deleted file mode 100755
3index fe39f65..0000000
4--- a/hooks/leader-elected
5+++ /dev/null
6@@ -1,18 +0,0 @@
7-#!/usr/bin/env python3
8-
9-# Load modules from $CHARM_DIR/lib
10-import sys
11-sys.path.append('lib')
12-
13-from charms.layer.basic import bootstrap_charm_deps
14-bootstrap_charm_deps()
15-
16-
17-# This will load and run the appropriate @hook and other decorated
18-# handlers from $CHARM_DIR/reactive, $CHARM_DIR/hooks/reactive,
19-# and $CHARM_DIR/hooks/relations.
20-#
21-# See https://jujucharms.com/docs/stable/authors-charm-building
22-# for more information on this pattern.
23-from charms.reactive import main
24-main()
25diff --git a/hooks/leader-settings-changed b/hooks/leader-settings-changed
26deleted file mode 100755
27index fe39f65..0000000
28--- a/hooks/leader-settings-changed
29+++ /dev/null
30@@ -1,18 +0,0 @@
31-#!/usr/bin/env python3
32-
33-# Load modules from $CHARM_DIR/lib
34-import sys
35-sys.path.append('lib')
36-
37-from charms.layer.basic import bootstrap_charm_deps
38-bootstrap_charm_deps()
39-
40-
41-# This will load and run the appropriate @hook and other decorated
42-# handlers from $CHARM_DIR/reactive, $CHARM_DIR/hooks/reactive,
43-# and $CHARM_DIR/hooks/relations.
44-#
45-# See https://jujucharms.com/docs/stable/authors-charm-building
46-# for more information on this pattern.
47-from charms.reactive import main
48-main()

Subscribers

People subscribed via source and target branches

to all changes: