Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explain Gitpod prebuild, add link to trigger a fresh build #365

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,10 @@ Setup a development environment and run this demo website with a single click (r
[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/#https://github.com/wagtail/bakerydemo/)

Once Gitpod has fully started, and a preview of the bakery website has appeared in the "Simple Browser" panel, click the arrow button to the right of the URL bar to open the website in a new tab.
Go to `/admin/` and login with `admin / changeme`.
Append `/admin/` to the URL and login with username `admin` and password `changeme`.

Gitpod uses [prebuilds](https://www.gitpod.io/docs/prebuilds) to reduce wait time, by installing dependencies and running builds **before** you start a new workspace.
Unfortunately, prebuilds work as a cache. You could get an outdated build. If that is the case, [trigger a new prebuild](https://gitpod.io/#prebuild/https://github.com/wagtail/bakerydemo).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How would one know if they get an outdated build?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One would encounter outdated packages, like the previous Wagtail, or missing commit from the Bakerydemo, or outdated third-party packages (that would be pinned with a range). Anything that is created in the init will be part of the prebuild. It is hard to say what, because anything in that stack can be updated in the mean time.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May be worth adding a nightly GitHub Action that fetches https://gitpod.io/#prebuild/https://github.com/wagtail/bakerydemo ? This way we guarantee some freshness

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That seems like a good idea, Dan!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zerolab Good idea! Would you be so kind as to submit a PR for that? I'm not too familiar with Github actions / schedules.

Note, we have some other projects that might require this feature too. See: https://gitpod.io/t/wagtail/projects

I'd assume that this current PR is good to merge too. Although the change that people encounter an outdated prebuild after the scheduled action is added is smaller, it is still there for 24h. And mentioning the behaviour is a good thing as nobody seems to be aware ;)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 from me on deploying

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just trying this now, I got the following error when following the trigger link: "Running prebuilds without a project is no longer supported. Please add your repository as a project in a team."

Going to https://gitpod.io/t/wagtail/bakerydemo/prebuilds and clicking "Run prebuild" seems to work as expected. Do we want to change the instructions?


## Setup with Vagrant

Expand Down