How to make repository public

I know how to make repositories visible to everyone, but how do I make public repositories clonable by users that aren’t registered on my server?

If the repo is public anyone should be able to clone it via HTTP/HTTPS without any additional setup; assuming you don’t have another authentication system in front of gitea.

If you mean fork the repo in your instance, they can’t without being registered.

1 Like

The repository is public, but peers can only git clone when able to enter a username + a corresponding password.

Assuming they’re cloning using HTTP/S please be sure you’ve configured your site to provide the correct base url and port.

I assume it wouldn’t work at all, if they were incorrect.

It’s possible. For instance one could be using SSH and not have provided an ssh key to gitea. Or, they could have an ssh key set but the port mapping is wrong (i.e. 22 vs 2222). If the issue is the base url you could have a hosts file setting they don’t. It’s really hard to say without more detail.

Issue is still there, even after updating to the newest version.

I’m not sure if you understood my last message (or if it made any sense) so I’m going to go out on a limb here and assume you need to use HTTP/S instead of git when cloning. It could be your using a non-standard port for git+ssh, which by default on most systems is 22 (the common port used for ssh).

I still don’t understand your point. You basically are saying that HTTP/S is the same as GIT and SSH. When I git clone ssh:// then obviously I don’t need a password, because I have my pub.key shared. I have to use a working username and its corresponding password to git clone from plain HTTPS which shouldn’t be an issue. It also can’t be related to any SSH port configuration because this problem existed weeks before I even touched the SSH configuration for Gitea.

I still experience this problem. I don’t know what else to do, as my Nginx configuration is so basic, that only essential elements are set and most of them are managed by Certbot anyway. I don’t see how that might cause public repositories to be viewable only after registration.

In the OP you did not mention you were using an Nginx server. Basic Nginx config or not if your users cannot clone public repos over HTTP you likely need to debug your Nginx integration. Start by reviewing your Nginx logs and consider again the advice given here:

Alternatively, consider my solution called High Tea:

The logs have no errors and my Nginx configuration is so basic, I basically can’t debug anything as it is so barebones.

Can anyone show me an nginx configuration that works for them including let’s encrypt?

I had the same issue. Trying to clone a public repo from https asked for username and password.
My problem was I had REQUIRE_SIGNIN_VIEW = true in my app.ini file
Changing it to false solved my problem



Thank you so much! I had this issue for almost a year now and you provided the simple fix I was looking for… I knew it wasn’t some weird reverse proxy related error… I am baffled how nobody else could chime in helpfully on this topic in all this time.

Again, thank you so much, you saved my instance. :grin: