git-credential-manager
git-credential-manager copied to clipboard
Support secretservice in headless environments
Feature description
It would be nice if secretservice would work out of the box on both desktop and headless linux environments (Debian/Ubuntu). I've seen some forums where they mention that libsecret secret-tool can work without X11. I'm not sure if this is a lot of effort to add, or it's just some configuration issue on the linux environment.
Source for the forum: https://gitlab.gnome.org/GNOME/libsecret/-/issues/27
I'm not a Linux expert by far, but I tried to get DBUS to work on an Ubuntu box without X11 for 1-2 days and couldn't. Maybe there's a way, but there's not an easy way.
I would try to debug this issue, but I cannot start the debugging environment in VSCode. Could anyone provide more info in the development.md how to start debugging the GCM Core code in VS Code under WSL?
-
I have windows 10 pro 2004
-
I have WSL 2 with ubuntu 20.04 server.
-
I have forked the repo and cloned in a folder on Ubuntu 20.04 server
-
I have 1.62.3 VS Code with plugins (remote development and c#)
-
I have dotnet sdk 5.0.404 on the Ubuntu 20.04 server
-
I have git version 2.34.1 on the Ubuntu
-
I have set the git config to : git config --global credential.credentialStore secretservice
-
I could build the solution with "dotnet build" , but "dotnet build -c LinuxDebug" does not work - Error is : /home/ubuntu/development/gcmcore/git-credential-manager/src/linux/Packaging.Linux/Packaging.Linux.csproj(23,5): error MSB3073: The command "/home/ubuntu/development/gcmcore/git-credential-manager/src/linux/Packaging.Linux/build.sh --configuration='Debug' --version='2.0.638.34290'" exited with code 1.
-
I can open from VSCode command palatte a Remote-WSL : New WSL Window and open the cloned gcm core repo
-
I can start debugging (Git Credential Manager (store) or (get) from VS Code debug menu
But I dont know how to interact with GCM running in my VS codes debugging mode. I try to interact with GCM via git credential fill the following way:
- I send the command in another terminal in the Ubuntu 20.04 server: git credential fill
- I write the following protocol=https host=github.com (I press enter here) (I press enter here again) It asks for username and pw .Seems like no interaction happens to GCM.
Can anyone show me what I miss here? I would like interact with GCM with a simple git cmd that the breakpoint would be hit at "src/shared/Core/Interop/Linux/SecretServiceCollection.cs"
Update: I got the debugging working from VSCode. Right now I'm trying with the manual relaunch of the DBUS, so that libsecret won't throw an exception.
I don't know that the core maintainers group has the expertise to properly address this one. Community help would be most welcomed, though!
Closing in favor of tracking this work as part of the wider effort to enhance credstore defaults on Linux.