After charm upgrade, adding networking-tools PPA fails due to add-apt-repo not using proxy

Bug #1929621 reported by Zachary Zehring
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Neutron Open vSwitch Charm
Fix Released
High
Corey Bryant

Bug Description

Scenario
========
Upgrade of neutron-openvswitch charm to the latest revision 282 (at the time at least) with the new enable-auto-restarts set to False. The juju action run-deferred-hooks was ran against the unit during a planned Maintenance Window.

Problem
=======
The run-deferred-hooks action hung for ~10 mins and finally failed. From the logs:

2021-05-17 20:51:44 DEBUG restart-services Cannot add PPA: 'ppa:~openstack-charmers/ubuntu/networking-tools'.
2021-05-17 20:51:44 DEBUG restart-services ERROR: '~openstack-charmers' user or team does not exist.
2021-05-17 20:51:44 DEBUG jujuc server.go:211 running hook tool "juju-log"
2021-05-17 20:51:44 INFO juju-log Failed executing 'add-apt-repository --yes ppa:openstack-charmers/networking-tools'. Will retry in 10 seconds

I found there was a recent commit that removed the passing of proxy settings to the "add-apt-repository" command when series was not xenial or trust [0].

Workaround
==========
Manually hacked the charmhelpers code for the unit to include passing proxy vars to the command. This was taken from the new commit.

Obviously, this bug will be fixed on a new release of charmhelpers library. This bug helps with posterity of the issue. I'd imagine this is not the only openstack charm affected by this issue, but it's the only one I've hit it on yet.

[0] https://github.com/juju/charm-helpers/commit/ba4dae4e7bba607f3e5b855d58f1594b39bf3466

Revision history for this message
Billy Olsen (billy-olsen) wrote :
Changed in charm-neutron-openvswitch:
status: New → Triaged
status: Triaged → In Progress
importance: Undecided → High
assignee: nobody → Corey Bryant (corey.bryant)
Revision history for this message
Billy Olsen (billy-olsen) wrote :
Changed in charm-neutron-openvswitch:
milestone: none → 21.10
status: In Progress → Fix Committed
milestone: 21.10 → 21.04
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.