Open hwebb opened 3 years ago
I had similar problems, but I found a workaround after lengthy and mostly fruitless research here: https://unix.stackexchange.com/a/548005
My WSL environment is ubuntu 22.04.
When you launch your WSL, run these commands:
sudo systemctl restart user@1000.service # to make sure that your user has a DBUS
sudo apt-get update
sudo apt-get install gnome-keyring libsecret-tools dbus-x11 # to install needed software
sudo killall gnome-keyring-daemon # to kill any running keyring daemons; most likely there will be none running since I think that WSL2 has the keyring daemon disabled by default
eval "$(printf '\n' | gnome-keyring-daemon --unlock)" # trick the system into thinking you've logged in, creating the needed keyring
eval "$(printf '\n' | /usr/bin/gnome-keyring-daemon --start)" # start up the keyring, making it available for xoauth
You can test to see if all this worked by running commands such as this:
secret-tool lookup foo bar
printf "aPassword" | secret-tool store --label="test" foo bar
secret-tool lookup foo bar
If you get the aPassword
string back after running these, then the keyring is set up and you are probably past this problem. Good luck!
Error when trying to connect via Linux SSH!