无法从 ubuntu 中的 bitbucket 克隆 git 存储库

Unable to clone git repository from bitbucket in ubuntu

我是 ubuntu、git 和 bitbucket 的新手。

所以,这是我的问题:

当我从 bitbucket 克隆为 https 时,出现以下错误:

fatal: unable to access 'https://user@bitbucket.org/project/my_project.git/': Failed to connect to bitbucket.org port 443: Network is unreachable

如果我从 bitbucket 克隆为 ssh,它会给我这个错误:

Cloning into 'my_project'... Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.

我已经在 Ubuntu 14.04 上安装了 Git 我错过了什么?没看懂。

甚至我在使用 git 从存储库克隆到本地时也遇到了同样的问题。确保您已正确生成 public 密钥和私钥:https://help.github.com/articles/generating-ssh-keys/ 并将 id_rsa(私钥)放在主目录的 .ssh 文件夹下