I have a web app that launches PowerShell to run git.
I have my local IIS configured to run as my own user account. The app pool is configured to use my account, and the process model has both loadUserProfile and setProfileEnvironment set to true.
The problem is that the git command is behaving differently in IIS vs IIS Express. The git config --show-origin -l
lists out identical settings from identical locations in both environments, so the settings both instances are using appear to be the same. Even though the same code is running is both places, the git fetch
command is succeeding under IIS Express, but failing under IIS with the error:
FATAL ERROR: Disconnected: No supported authentication methods available (server sent: publickey)
fatal: Could not read from remote repository.
Please make sure you have the correct access rights and the repository exists.
I cannot find an explanation for this. It's the same web app, either published to my local IIS or running directly in Visual Studio. Git config settings appear to be identical in all 4 config files that Git accesses on windows, and yet connections to the remote repository are failing in one environment but not the other. The same user account is used to run the process in both places.