charm should set the application version

Bug #1866040 reported by Kevin W Monroe
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Calico Charm
Fix Released
Low
Mateo Florido
Containerd Subordinate Charm
Fix Released
Low
Mateo Florido

Bug Description

Set the application version for containerd so it's easy to find it from 'juju status'. We do this for other charms, e.g.:

https://github.com/charmed-kubernetes/charm-flannel/blob/master/reactive/flannel.py#L233

You may have to call out to apt to find the right value for containerd.

Changed in charm-containerd:
importance: Undecided → Wishlist
Joseph Borg (joeborg)
Changed in charm-containerd:
status: New → Confirmed
assignee: nobody → Joseph Borg (joeborg)
Changed in charm-containerd:
importance: Wishlist → High
milestone: none → 1.18
Revision history for this message
Joseph Borg (joeborg) wrote :
George Kraft (cynerva)
Changed in charm-containerd:
status: Confirmed → Fix Committed
Changed in charm-containerd:
status: Fix Committed → Fix Released
Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

This is still a problem:

tvansteenburgh@slipgate:~$ juju status | head
Model Controller Cloud/Region Version SLA Timestamp
one tannahill-default tannahill/default 2.7.8 unsupported 16:33:31-04:00

App Version Status Scale Charm Store Rev OS Notes
containerd active 4 containerd jujucharms 90 ubuntu
easyrsa 3.0.1 active 1 easyrsa jujucharms 318 ubuntu
etcd 3.4.5 active 3 etcd jujucharms 531 ubuntu
flannel 0.11.0 active 4 flannel jujucharms 492 ubuntu
kubeapi-load-balancer 1.14.0 active 1 kubeapi-load-balancer jujucharms 695 ubuntu exposed
kubernetes-master 1.18.6 active 2 kubernetes-master jujucharms 850 ubuntu
tvansteenburgh@slipgate:~$ juju run -u containerd/0 -- dpkg -l containerd
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-==============-======================-============-=================================
hi containerd 1.3.3-0ubuntu1~18.04.2 amd64 daemon to control runC

Changed in charm-containerd:
status: Fix Released → Confirmed
importance: High → Low
milestone: 1.18 → none
Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

Ugh, see paste for easier-to-read output: https://pastebin.ubuntu.com/p/sqmqxQY8MN/

Revision history for this message
George Kraft (cynerva) wrote :

I didn't encounter this on a fresh deploy of stable rev 88. I checked rev 90 and the application_version_set code is there. I'm not seeing any glaring flaws in the code that would cause it to fail, either on new deploy or from an upgrade.

Any reproduction details? Also output from `juju debug-log -i containerd` would help.

Revision history for this message
George Kraft (cynerva) wrote :

Make that `juju debug-log -i containerd --replay`.

Changed in charm-containerd:
status: Confirmed → Incomplete
Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

I started with the 1.15 bundle, which uses containerd rev 20. Then I upgraded to rev 88. App version is not displayed before or after the upgrade.

Output of `juju debug-log -i containerd --replay --no-tail | pastebinit`:
https://paste.ubuntu.com/p/txTwt9gS7W/

Revision history for this message
George Kraft (cynerva) wrote :

Thanks. It looks like the publish_version_to_juju handler[1] is not running because the containerd.installed flag is not set. That flag did not exist in rev 20. It looks like it never got set post-upgrade.

[1]: https://github.com/charmed-kubernetes/charm-containerd/blob/78e5b90a90c90445e8600b0855e60af9bd5e5e9a/reactive/containerd.py#L238

Changed in charm-containerd:
status: Incomplete → Triaged
Revision history for this message
Kevin W Monroe (kwmonroe) wrote (last edit ):

While we have a version being reported now, it's not correct for containerd (it's the golang version vs the app version). Let's fix this up for our next release.

Changed in charm-containerd:
milestone: none → 1.25+ck1
assignee: Joseph Borg (joeborg) → nobody
Revision history for this message
Mateo Florido (mateoflorido) wrote :
Changed in charm-containerd:
assignee: nobody → Mateo Florido (mateoflorido)
status: Triaged → Fix Committed
Changed in charm-containerd:
milestone: 1.25+ck1 → 1.26
Revision history for this message
Kevin W Monroe (kwmonroe) wrote :
Changed in charm-calico:
importance: Undecided → Low
milestone: none → 1.26
status: New → Fix Committed
Changed in charm-calico:
assignee: nobody → Mateo Florido (mateoflorido)
Adam Dyess (addyess)
Changed in charm-calico:
status: Fix Committed → Fix Released
Changed in charm-containerd:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.