0

In Windows:

When cloning GIT repository, I can do this successfully:

git clone https://[email protected]/clientes/sample/project.git

However, when I do:

git clone ssh://[email protected]:17177/clientes/sample/project.git

After the log in banner is displayed, this error is shown:

fatal: '/clientes/sample/project.git' does not appear to be a git repository
fatal: Could not read from remote repository.

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

In MacOS:

When using HTTPS way, a SSL certificate expired error is shown.

When using SSH way, the same error as Window.

How can I solve those problems?

6
  • Seems like /clientes/sample/project.git is not a git repository on that server. How can I solve those problems? Use the correct path. Commented Jul 14, 2022 at 13:55
  • If it's a public GitLab instance, we might be able to reproduce the problem and suggest the correct solution, with an actual repository name. If it's a private GitLab instance, we can't. It could be a configuration issue that needs to be addressed by your organization: a case where local assistance will be far more useful than asking here. Commented Jul 14, 2022 at 13:58
  • @tkausl The path is correct since it works using HTTPS. Or, when using SSH I should specify the path in a different way? Commented Jul 14, 2022 at 14:10
  • @chepner I installed GitLab in my own server. I have never had problems since I use HTTPS to do all operations. The problem started when I hired a developer that uses MacOS. She cannot clone by either HTTPS or SSH. That is why I tried to clone using SSH in my Windows machine and I couldn't too. Commented Jul 14, 2022 at 14:12
  • OK, then this is specifically a GitLab issue (namely you need to configure it to allow SSH connections), not a Git issue. Commented Jul 14, 2022 at 15:05

2 Answers 2

1

the problem was that I was using my Git user. Git was installed using git user so I changed to git user and the repository error was gone

Any GitLab instance (on-premise or SaaS gitlab.com) never allows user SSH access.
It only allows one account, the 'git' service account.

The user authentication is then performed through the public SSH key used to establish that connection, since said public key is registered to your GitLab account.

Sign up to request clarification or add additional context in comments.

Comments

0

Either

  1. You need to sort out acces on the repository settings.

  2. Create license, terms and certificate file on the repository. By the looks of it it can't authenticate the certificates. It's quite easy git should just create one automatically when you create a repository. Or create one yourself.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.