Repository navigation
Download a prebuilt managed PHP before building one - #8
Merged
Merged
Conversation
A managed PHP that is not in the SKERNEL home yet is looked up in the releases of `super-kernel-tools/runtimes` by the runtime's own key: platform, PHP version, and the hash of its extensions, their selected versions, the toolchain, and the build options. The archive is installed only when it matches its published SHA-256 digest, its manifest names the requested PHP, platform, and extensions, both binaries match the digests in the manifest, and its PHP runs here and reports extension versions the installation accepts. A runtime that is not published is built with static-php-cli as before. The new `prebuilt` setting of `skernel.json`, `true` by default, turns the lookup off: with `false` every runtime is built on the machine and the repository is never contacted. `new` has no project file yet, so the PHP of SKERNEL's own Composer may always be downloaded. The test suite and the format check pass; no test reaches the network. Co-Authored-By: Claude <noreply@anthropic.com>
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.
A managed PHP that is not in the SKERNEL home yet is looked up in the releases of super-kernel-tools/runtimes before it is built.
What changes for a developer
Before, the first
run,build, orpackageon a machine compiled PHP with static-php-cli, which needs build tools and minutes:Now it downloads the same build when one is published, and needs no build tools:
A runtime that is not published is built as before, after one line that says so. A project turns the download off in
skernel.json:{ "prebuilt": false }How it works
Src\Toolchain\PrebuiltRuntimefetchesphp-<version>-<platform>-<key>.tar.gzand its.sha256file from the releasephp-<version>, the key being the name of the runtime's directory, so only the exact build SKERNEL would do matches.prebuiltis a setting ofskernel.json,trueby default, described inskernel.schema.jsonand both READMEs. Withfalsethe repository is never contacted.newhas no project file yet, so the PHP of SKERNEL's own Composer may always be downloaded.Validation
The test suite and the format check pass, and no test reaches the network. A real runtime was packed in the published format and installed from a local address.
🤖 Generated with Claude Code