Git with a cup of tea! Painless self-hosted all-in-one software development service, including Git hosting, code review, team collaboration, package registry and CI/CD
After setting Gitea up under a gitea user and group, it can be desirable to be able to use git@example.com:user/repo.git. This can be enabled by creating a git user with the same UID, e.g. via useradd -o -u $(id -u gitea) git.
At the moment, this causes issues because the user check is based on the name, not the UID.
I am using the Builtin ssh server. The service is running as gitea. If I set git for SSH_USER, it does not work. It only works if SSH_USER is also gitea.
Feature Description
After setting Gitea up under a
gitea
user and group, it can be desirable to be able to usegit@example.com:user/repo.git
. This can be enabled by creating agit
user with the same UID, e.g. viauseradd -o -u $(id -u gitea) git
.At the moment, this causes issues because the user check is based on the name, not the UID.
https://github.com/go-gitea/gitea/blob/ff9b6fa6639bacd4770b0e81661697af35c78aa6/modules/setting/setting.go#L999-L1005
https://github.com/go-gitea/gitea/blob/ff9b6fa6639bacd4770b0e81661697af35c78aa6/modules/setting/setting.go#L512-L523
Would it be possible to change this check to be based on the UID?
Screenshots
No response