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

Call out conditions under which child Previews might run init and update #216

Open
dacharyc opened this issue Jul 6, 2020 · 0 comments
Open
Assignees

Comments

@dacharyc
Copy link
Contributor

dacharyc commented Jul 6, 2020

A Tugboat user in the Support Slack recently ran into an issue where child previews were running what appeared to be unexpected init and update steps for a pull request Preview, instead of using the init and update from the Base Preview.

The issue turned out to be that the base Preview was using tugboatqa/php:7.3-apache, and the pull request preview was using tugboatqa/php:7.2-apache. In that case, we expect Tugboat to pull the image from the config in the PR branch and run all three commands just for that service. However, we don't call that out explicitly enough in the documentation site.

Update the Building New Previews page to better communicate this: https://docs.tugboat.qa/building-a-preview/work-with-base-previews/building-new-previews/

(Maybe add a callout?)

Ben says about this:

the config.yml is pulled directly from the PR branch, not the merged version. github doesn’t readily give that to us via their API (same with bitbucket and gitlab), and merging it locally without any git history would be error-prone at best

Should add a section to docs somewhere calling this out, too. Maybe on the "Create a Tugboat Config File" page: https://docs.tugboat.qa/setting-up-tugboat/create-a-tugboat-config-file/

And on the Leverage Service Commands page: https://docs.tugboat.qa/setting-up-services/how-to-set-up-services/leverage-service-commands/

Additionally, in the "How Base Previews Work" section of the How Previews Work page: https://docs.tugboat.qa/building-a-preview/preview-deep-dive/how-previews-work/#how-base-previews-work

We state:

When you set a Base Preview, new Previews that match that Base Preview type - including Previews that are built automatically from pull requests - use the Base Preview as a starting point, and build only from the build stage. This means that if you’re making changes that would be processed during init or update stages, or changing a Docker image, you’ll need to either rebuild the Base Preview, or build the Preview from scratch without the Base Preview.

That's not entirely correct; when you change a Docker image, the pull request Preview will process the init and update stages for that service. Update this callout, and maybe add some more info to this page about it.

@dacharyc dacharyc added the bug label Jul 6, 2020
@dacharyc dacharyc self-assigned this Jul 6, 2020
@q0rban q0rban removed the bug label Aug 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants