My Gitea version is 1.2.3 and it's install on a gentoo dedicated server. I created my SSH key on another dedicated server with my user (not the root one).
On the Gitea GUI, I created an Organization and a repo for that organization, my gitea user is the owner of all of that (not the root account)
When I go to [Organization]/ [MyRepo] > Settings > Deploy keys, I add the ssh key of my remote user. Gitea add that key to the authorized_key file in the .ssh git user (git user is the user for gitea)
From my remote, when I tried that :
ssh git@[gitea_server_ip]
I've got this message :
Hi there, You've successfully authenticated, but Gitea does not provide shell access.
If this is unexpected, please log in with password and setup Gitea under another user.
So SSH work well, but when I tried a push or clone, I get that :
git push -u origin master
Answer :
Gitea: Key permission denied
Cannot push with deployment key: 5
fatal: Could not read from remote repository
Please make sure you have the correct access rights and the repository exists.
It's seems to be a gitea authentication problem but I don't find the answer, thanks.