• ローカルで SSH agent を起動、git —global 設定すればOK

The extension will automatically copy your local .gitconfig file into the container on startup so you should not need to do this in the container itself.

拡張は自動的にローカル環境の.gitconfigをコンテナにコピーする ローカルで設定しておけばコンテナ内で再度設定する必要はない

リポジトリのクローンにSSH キーを使用する場合

There are some cases when you may be cloning your repository using SSH keys instead of a credential helper. To enable this scenario, the extension will automatically forward your local SSH agent if one is running.

拡張機能は、もしローカルのSSH agentが動作している場合、認証情報をforwardする

First, you should ensure that SSH agent forwarding is enabled on the host. Search for the AllowAgentForwarding option in sshd_config (usually located at /etc/ssh/sshd_config or %programdata%\ssh\sshd_config). If not already, you should set it to yes and reload or restart the sshd service.

まず、SSH agent forwarding がホスト上で有効化されていることを確認 etc/ssh/sshd_configのAllowAgentForwarding を設定

You can add your local SSH keys to the agent if it is running by using the ssh-add command. For example, run this from a terminal or PowerShell:

ssh-add 

ssh-add コマンドで鍵をSSH agentに追加

Linux環境における具体的なステップ

//ローカル環境でgitconfig設定が存在することを確認
cat ~/.gitconfig

//存在しなければ設定
git config --global user.name "Your Name"
git config --global user.email "your.email@address"