See related #431
and upcoming #439
workaround - local docker and shared drive for AVD/local-machine in #429
Summary of procedure
# generate key on cloud shell
sh-keygen -m PEM -t rsa -P ""
# save to default id_rsa dir/file
cat ~/.ssh/id_rsa.pub
# upload/register public key on CSR
# return to cloud shell and clone
# replace your email, project and repo (gcp-networks)
git clone ssh://michael@obrienlabs.dev@source.developers.google.com:2022/p/prj-b-cicd-fgbs/r/gcp-networks
cd gcp-networks
# verify
git status
Use the default id_rsa key name
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ ls ~/.ssh
config csr_id_rsa csr_id_rsa.pub google_compute_engine google_compute_engine.pub google_compute_known_hosts known_hosts obrienlabs_org_github
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ ssh-keygen -m PEM -t rsa -P ""
Generating public/private rsa key pair.
Enter file in which to save the key (/home/michael/.ssh/id_rsa):
Your identification has been saved in /home/michael/.ssh/id_rsa
Your public key has been saved in /home/michael/.ssh/id_rsa.pub
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ cat ~/.ssh/id_rsa.pub
ssh-rsa AAAA...1616-default
register key with CSR
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ git clone ssh://michael@obrienlabs.dev@source.developers.google.com:2022/p/prj-b-cicd-fgbs/r/gcp-networks
Cloning into 'gcp-networks'...
warning: You appear to have cloned an empty repository.
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ ls gcp-networks/
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ ls
gcp-environments gcp-networks gcp-policies
michael@cloudshell:~/tef-oldev3/_test_repo (tef-oldev3)$ cd gcp-networks/
michael@cloudshell:~/tef-oldev3/_test_repo/gcp-networks (tef-oldev3)$ git status
On branch master
No commits yet
nothing to commit (create/copy files and use "git add" to track)
See related #431 and upcoming #439 workaround - local docker and shared drive for AVD/local-machine in #429
Summary of procedure
Use the default id_rsa key name
register key with CSR
retrofit the script
security review email