Closed ryan-beisner closed 9 years ago
The cause of this is that juju run
does things as root on the unit, whereas juju ssh
does things as ubuntu on the unit.
FYI:
ubuntu@beisner-bastion:~/bzr/next/neutron-gateway$ apt-cache policy amulet
amulet:
Installed: 1.11.2-0ubuntu2~ubuntu14.04.1~ppa1
Candidate: 1.11.2-0ubuntu2~ubuntu14.04.1~ppa1
Version table:
*** 1.11.2-0ubuntu2~ubuntu14.04.1~ppa1 0
500 http://ppa.launchpad.net/juju/stable/ubuntu/ trusty/main amd64 Packages
100 /var/lib/dpkg/status
Moving away from juju run to juju ssh sentry.py has broken the scenario where sentry_unit.file_stat(filename) is used to get file or dir attrs for files not owned by the ubuntu user.
Ultimately, filesystem_data.py gets: OSError: [Errno 13] Permission denied: '/etc/neutron/neutron.conf'
Because the dir and file are root-owned.
The impact is that all of the OpenStack Charm amulet tests are failing, unable to stat the files as they had been able to prior to this change.
https://github.com/juju/amulet/commit/b6da1c3c98622ee9a28e5da21d3032dd8de0471e