Juju ssh (ssh-agent?) stops working - what to do?

Hello!

A while ago, I was messing with juju ssh and ssh-agent (needed for some bootstrap activities) and now I can’t seem to recover the ability to do “juju ssh”.

I think this is related to the juju snap, but I can make this work prior to me messing with the ssh-agent.

Is there anyone that knows more about or has some pointers on this topic?

@jameinel helped me out on the ssh-agent which I havent been able to resolve.

ssh ubuntu@ipipipip still works…

The issue, as I understand it, is that by default if you just run ssh-agent it will set itself up with a socket under /tmp/* which is accessible by your user account, but not from within a confined snap, where /tmp gets rebound to a per-snap directory. What I use is:

eval `ssh-agent -a $HOME/dev/tmp/ssh-XXXXX`

It needs to be under $HOME, and not a hidden (.) directory. Then that should be the same directory from inside the snap as outside the confined snap.