We have GitLab set up internally (v 9.0.5). 40 private projects have been made public. When a new user logs into GitLab, there is a section at the bottom of their screen which says:
There are 40 public projects on this server.
Public projects are an easy way to allow everyone to have read-only access.
They click on the "Browse projects" button.
The next page comes up with "No projects found."
Is there a configuration issue with the new user? The 40 repositories have their visibility set to "Public" and the repository, merge requests, and pipelines are all set to "Everyone with access."
What's missing?
Designs
Child items
...
Show closed items
Linked items
0
Link issues together to show that they're related or that one is blocking others.
Learn more.
@jfota I transferred this issue to the GitLab CE issue tracker as the tracker where the issue was originally posted is for issues relating to the GitLab.com platform.
@jfota That does sound like the incorrect behaviour. We'll need to check the projects that the user is permitted to see via the Rails console to identify the problem here:
Hi, I have a problem that is very similar to @jfota's. Some user reported that she can only see 2 projects on her dashboard, but she owns 5 and has been granted access to 3 more. She gets 404 Not Found if she tries to access URL of any "missing" project manually. I have verified this behavior using Impersonate function.
What's weird is that I can see all her projects in /admin/users/login and the complete list is returned as well via GitLab API.
The query you posted above returns 2 for user.authorized_projects.count and 8 for fresh_auths.map(&:project).count. I tried to google for a while and came upon gitlab-rake gitlab:user:check_repos[login], which only checked the 2 projects.
@markglenfletcher I've run the command for all users and the affected user can finally see all her projects in the dashboard (at least via Impersonate function). Thank you very much.
I ran the commands. No change from what I reported. According to the public_projects_for_user.count, there should be 45 public projects I should be able to browse, but when I click on the "Browse Projects" button I still see "No Projects Found".
If the VisibilityLevel::public_to_user method is returning the 45 projects, then they should be displayed in the explore projects list. I can't see anywhere that the result of the query, or the views, is cached so I don't think that this is the issue but can you try clearing the cache just in case?
Because these projects are public they should be accessible to users that have not logged in to. Is this the case when you visit the /explore without logging in or are the projects missing there too?