Repository navigation
fix(installer): prebuilt dist from dist.url, logged rebuild fallback, keep host-modules.json (D9) - #51
Open
roncodes wants to merge 1 commit into
Open
fix(installer): prebuilt dist from dist.url, logged rebuild fallback, keep host-modules.json (D9)#51roncodes wants to merge 1 commit into
roncodes wants to merge 1 commit into
Conversation
…ld with the reason logged ServiceReleaseSource downloads a release's prebuilt dist from the dist.url the Registry Service names (/v1/instances/me/releases/<id>/dist), falling back to the npm dist route for services without one. A Registry Service release whose dist is missing or cannot be downloaded now installs the engine package and rebuilds, with the reason in the job log, result.prebuilt_skipped and the application log. A checksum mismatch still fails the job (ChecksumMismatchException). Console rebuilds run with FLEETBASE_HOST_MODULES=1, so a non-production build keeps dist/host-modules.json and later installs can still take prebuilt dists.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The installer now downloads a release's prebuilt dist from
dist.urland records why whenever it rebuilds the console instead. This is the last part of D9 from the end-to-end walk; it goes with fleetbase/registry#13, which addsdist.urland the instance download.ServiceReleaseSourcetakes the dist from thedist.urlthe Registry Service names (/v1/instances/me/releases/<id>/dist; a path is resolved against the configured service). Services that send nourlkeep using<service>/npm/<engine>/-/dist/<version>. The instance token is still sent only to URLs on the configured service.result.prebuilt_skippedand the application log. Before this change a missing dist rebuilt silently, and a failed dist download failed the whole install.ChecksumMismatchExceptionand are never worked around.host-modules.jsonsurvives rebuilds. Console rebuilds run withFLEETBASE_HOST_MODULES=1. The console only writesdist/host-modules.jsonin production builds, and the installer builds with--environment <APP_ENV>. So the first rebuild on a development instance dropped the file, and the console refused every prebuilt engine after that. The e2e walk console was in exactly this state after its last rebuild.Tests:
RegistryServiceInstallTestcovers thedist.urlhandling, the download-failure fallback, the logged reason for a missing dist, andFLEETBASE_HOST_MODULESon the build. Bridge CI still doesn't runcomposer test:unit(it's commented out inserver.yml), so these tests haven't run in CI. The installer path was exercised live in the e2e setup instead (see the report).