I have not modified that part in my PR, however, I think writing to /etc/profile.d/juju-proxy.sh should only be done for the legacy proxy settings as you say.
I suppose it was not a problem with the new proxy settings since /etc/juju-proxy.conf was never written to and there is a check for the existence of that file in the resulting juju-proxy.sh.
Vern,
I have not modified that part in my PR, however, I think writing to /etc/profile. d/juju- proxy.sh should only be done for the legacy proxy settings as you say.
https:/ /github. com/juju/ juju/pull/ 11713/files# diff-2e72a75bbc 42f70552be8a909 2cc7f8fL322- L323
I suppose it was not a problem with the new proxy settings since /etc/juju- proxy.conf was never written to and there is a check for the existence of that file in the resulting juju-proxy.sh.