local environment broken with root perms
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-core |
Fix Released
|
Critical
|
Tim Penhey |
Bug Description
Currently using trunk (r2207) I see several failures wrt ssh and files/dirs owned by root.
After doing "sudo juju bootstrap -e local --debug"
I end up having a new
~/.ssh/
Trying to deploy something fails:
$ juju deploy -e local ubuntu --debug
error: cannot load ssh client keys: open /home/jameinel/
This is extra bad, because 'deploy' doesn't need to SSH into anything, so I don't quite see why it would break.
If I chown -R jameinel: ~/.juju/ssh then things seems to work.
But:
a) I don't think we want to mutate/write the host's ~/.ssh/
b) The ~/.juju/ssh directory ends up owned by root rather than the user, and then it can't be read by future commands
Related branches
- Juju Engineering: Pending requested
-
Diff: 254 lines (+155/-8)4 files modifiedcmd/juju/main_test.go (+1/-7)
utils/ssh/clientkeys.go (+6/-1)
utils/sudo.go (+57/-0)
utils/sudo_test.go (+91/-0)
Changed in juju-core: | |
milestone: | 1.17.1 → 2.0 |
Changed in juju-core: | |
status: | In Progress → Fix Committed |
Changed in juju-core: | |
milestone: | 2.0 → 1.17.1 |
Changed in juju-core: | |
status: | Fix Committed → Fix Released |
OK, there are two issues here.
a) modifying ~/.ssh/ authorized_ keys is wrong, and the worker that was messing with that has been stopped.
... r2207? that really shouldn't be modifying the host authorized_keys...
b) the ~/.juju/ssh directory owned by root is a problem.