Add a juju action to retrieve admin password
Bug #1907063 reported by
Tom Haddon
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
charm-k8s-wordpress |
Fix Released
|
Medium
|
Tom Haddon |
Bug Description
Currently the instructions to retrieve the admin password for Wordpress are to run:
microk8s.kubectl exec -ti -n wordpress wordpress-
This should instead be possible via a juju action.
Related branches
~mthaddon/charm-k8s-wordpress/+git/charm-k8s-wordpress:admin-password-action
- Stuart Bishop (community): Approve
- Wordpress Charmers: Pending requested
-
Diff: 426 lines (+269/-25)7 files modifiedREADME.md (+2/-2)
actions.yaml (+2/-0)
src/charm.py (+28/-1)
src/leadership.py (+218/-0)
src/wordpress.py (+1/-12)
tests/unit/test_charm.py (+15/-1)
tests/unit/test_wordpress.py (+3/-9)
Changed in charm-k8s-wordpress: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
assignee: | nobody → Tom Haddon (mthaddon) |
To post a comment you must log in.
This has been added, but we've introduced a problem as follows:
application- wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password Traceback (most recent call last): wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password File "./src/charm.py", line 13, in <module> wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password from leadership import LeadershipSettings wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password File "/var/lib/ juju/agents/ unit-wordpress- 0/charm/ src/leadership. py", line 20, in <module> wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password from typing import Any, Iterable, Dict, MutableMapping, Protocol wordpress: 10:53:01 WARNING unit.wordpress/ 0.get-initial- password ImportError: cannot import name 'Protocol'
application-
application-
application-
application-
application-
The workload pod is on bionic, which doesn't support "Protocol". Need to confirm if it's possible to simply switch the image to focal, or whether we need to update the leadership library to deal with older versions of "typing".