Provide pre-built DLLs when there is no connectivity #298
Replies: 11 comments
-
@Seldaek, this change has an impact on the composer? |
Beta Was this translation helpful? Give feedback.
-
Yes this would not be doable as you describe just in pie I suppose, unless pie stores/retrieves this stuff in the extra key. |
Beta Was this translation helpful? Give feedback.
-
Okay, this schema is possible: {
"name": "xdebug/xdebug",
"version": "3.1.7",
"dist": {
"url": "https://xdebug.org/files/xdebug-3.1.7.zip",
"type": "zip"
}
"extra": {
"windows-dist": {
"url": "https://www.smarty.net/files/Smarty-3.1.7-8.4-ts-vs17-x86_64.zip",
"type": "zip"
},{
"url": "https://www.smarty.net/files/Smarty-3.1.7-8.4-ts-vs17-x86.zip",
"type": "zip"
},{
"url": "https://www.smarty.net/files/Smarty-3.1.7-8.4-nts-vs17-x86_64.zip",
"type": "zip"
},{
"url": "https://www.smarty.net/files/Smarty-3.1.7-8.4-nts-vs17-x86.zip",
"type": "zip"
}
}
} |
Beta Was this translation helpful? Give feedback.
-
I'm starting to understand what you're asking for now. You are asking for another way of downloading pre-built DLLs (your use case being that you cannot use public internet). At the moment, the only supported way PIE fetches DLLs is by downloading from the release assets on a GH release: https://github.com/php/pie/blob/main/docs/extension-maintainers.md#windows-support We can evaluate in the future other ways of downloading prebuilt DLLs such as this, but this isn't something I'll be able to look at just yet. |
Beta Was this translation helpful? Give feedback.
-
This feature can be used by the maintainer in the Now you use the GitHub release feature, but some other SVC systems exist and some other source code hosting exists (Zoho, Bitbucket, GitLab...). |
Beta Was this translation helpful? Give feedback.
-
We managed to build a private extension by wrapping it inside a fake extension, would be nice to see 1st party support for this. |
Beta Was this translation helpful? Give feedback.
-
@asgrim The extra data can be put in the Pros:
Cons:
|
Beta Was this translation helpful? Give feedback.
-
Hi @asgrim, I have a POC to 'composer' repository compatible with Pie 1.0. This POC can provide the extension information from the PECL extension information and convert the PECL source archive to a zip archive. Now, I don't have any way to provide prebuilt DLLs with my private repository. Any idea how to provide it? Pie extension? |
Beta Was this translation helpful? Give feedback.
-
I'm not sure this is a great idea; PECL will eventually be removed, so this would break when that happens. We shouldn't be encouraging installation of outdated/unsupported versions IMO. That said, I have no idea how this point relates to this thread. Perhaps create a discussion or separate issue? Please stop conflating threads! :)
Prebuilt DLLs only work with Github at the moment. There is a ticket to add them for Gitlab eventually (#226) and Bitbucket (#138). Really, the title of this ticket makes no sense; you don't pull the archives from Private Packagist, you pull it from the VCS repo (Github/Gitlab/Bitbucket). Packagist/Private Packagist/Satis/other Composer repos are JUST metadata, you can't store code archives on there. PIE predefines how the archives should be named for the release on Github releases, so that is really all that is necessary to make this work. Perhaps I'm not fully understanding what you're asking, but if I'm understanding correctly, it doesn't really make sense I think. |
Beta Was this translation helpful? Give feedback.
-
Thanks for your answer. Some PHP "unmaintained" extensions can be built for PHP 8+ without code change. But it's not the subject. Perhaps, the proxy is a better name. I need to use Pie in a network disconnected from the Internet. Nexus provides a similar behaviour to dependencies managed with Composer. I can download the source code archive from the local server after changing the URL in the package metadata. But no way for the prebuilt DLLs. I'm sorry if I expressed myself poorly. Thank you for taking the time to understand my problem. |
Beta Was this translation helpful? Give feedback.
-
Hmm, perhaps This does feel like a bit of an edge case though; in general PIE (as well as Composer) assume connectivity, so without connectivity, things are somewhat limited. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Some companies or state organizations do not allow the servers or the developer's computer to access the Internet. Others have a private PHP extension. I use the
Satis
term to speak of the private packagist.I try to understand how PIE works with a private composer repository and how to get the DLL to install it. Without reading the code ;-)
I have tried with Satis and xdebug. The installation has noway.
Composer repository and satis generated files do not contain the PHP extension configuration to build or get the DLL.
For each package information provided by Satis, this is the minimal information:
This information is minimal for PHP library. But for PHP extension, some other information is needed: DLL download information, and compilation options...
I have this idea of JSON structure for an extension package
The source archive contains the composer.json file with the build options and other information. However, no information about the DLLs.
With the public packagist, PIE gets the DLL from the Release Asset and searches the right archive corresponding with the name template (see doc).
How to download DLL from Satis or another private composer repository?
Beta Was this translation helpful? Give feedback.
All reactions