gitpod-io / gitpod

The developer platform for on-demand cloud development environments to create software faster and more securely.
https://www.gitpod.io
GNU Affero General Public License v3.0
12.79k stars 1.23k forks source link

Other users can't load my prebuild #18752

Open shaal opened 1 year ago

shaal commented 1 year ago

Bug description

DrupalPod repo is based on the fact that I run the prebuild ahead of time, and all other users open the workspace and ready to work. A user reported that when they open a workspace with DrupalPod, instead of loading the prebuild, when opening the workspace init task starts running.

Steps to reproduce

Open https://github.com/shaal/gitpod--prebuild-for-other-users in Gitpod by following this link - https://gitpod.io/#https://github.com/shaal/gitpod--prebuild-for-other-users

There's a 60 seconds countdown timer that already ran in prebuild, if you see the countdown in your workspace, it failed loading prebuild.

Workspace affected

No response

Expected behavior

When a prebuild is available, any user who open the workspace should get the prebuild.

Example repository

https://github.com/shaal/gitpod--prebuild-for-other-users https://github.com/shaal/DrupalPod

Anything else?

It seems to be inconsistent who gets to load prebuild and who doesn't. @rfay can load prebuilds of my repos, @tyler36 cannot load prebuild of my repos.

Tyler36 couldn't load the prebuild for https://github.com/shaal/ddev-gitpod, after I confirmed the prebuild loads for me. I asked him to fork my ddev-gitpod repo, and generate the prebuild in his Gitpod account - https://github.com/tyler36/ddev-gitpod He was able to open his fork and it loaded the prebuild for him. I tried opening his fork but it did NOT load the perbuild for me.

rfay commented 1 year ago

Was it ever intentional with Gitpod that one user would be able to use the prebuilds of another user?

rfay commented 1 year ago

@shaal a better title might be "Other users can't load my prebuild" or something like that?

shaal commented 1 year ago

@rfay I found this in the docs -

Prebuilds are shared!

Gitpod can trigger a prebuild whenever there is a commit to a repository. That prebuild will then be used for all new workspaces opened on that branch. This is ideal for working together on branches for testing or code reviews. https://www.gitpod.io/docs/configure/projects/prebuilds#prebuilds-are-shared

axonasif commented 1 year ago

Hi @shaal, sorry for the trouble.

Can you please check if you have prebuilds enabled on the project settings for the repos you mentioned?

Screenshot 2023-09-22 at 7 47 23 PM
shaal commented 1 year ago

@axonasif yes, prebuilds are enabled on these projects/repos. I use these prebuilds myself, and I've been using prebuilds successfully for a couple of years now. The new issue is that some people do not get the prebuild loaded in their workspace, while other people do.

shaal commented 1 year ago

(removed this comment)

tyler36 commented 11 months ago

Still having the issue with not get prebuilds from @shaal 's repo.

axonasif commented 9 months ago

Sorry for the late update on this. There has been a few other people asking about it. I learned that only organization members tied to the Gitpod project can load the prebuild.

See https://www.gitpod.io/docs/configure/projects/prebuilds#prebuilds-are-only-available-to-organization-members

We may need to introduce an option to allow public loading of prebuilds.

shaal commented 8 months ago

@axonasif The approach you described in your last comment would be a breaking change, since previously everyone was able to use the existing prebuilds for a repository.

This is also related to my separate feature request at https://github.com/gitpod-io/gitpod/issues/19175 - if Gitpod saved a prebuild whenever someone opened a commit or branch in a workspace (after running all .gitpod.yml tasks), it could save a lot of resources. By default caching that state as a prebuild, Gitpod could avoid re-running all the setup each time, which would be more efficient.

github-actions[bot] commented 4 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

tyler36 commented 4 months ago

Still on issue.