Git

Google云平台虛擬機上的 GitLab

  • March 18, 2018

我正在嘗試在 Google Cloud Platform 上執行 gitlab。我遵循了本教程:https ://docs.gitlab.com/ce/install/google_cloud_platform/index.html但現在我無法將送出推送到遠端。

git@33.22.33.22: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

SSH 密鑰已添加到 Google Cloud Platform VM 以及 Gitlab 帳戶。我相信我必須以某種方式通過 ssh 啟用 git,但不確定這些事情如何與 Google Cloud Platform 的安全性配合使用。

所以問題出在其他地方。

我最近更改了 VM 的 IP 地址(具有靜態 IP 地址)。不幸的是,我忘記在 GitLab 設置中更改 IP,所以複製連結仍然指向舊連結。因此Could not read from remote repository.

引用自:https://serverfault.com/questions/903244