Repository navigation
Conversation
|
I am trying to understand about the nuget cache for vcpkg. Will you give that a chance? |
I personally cannot volunteer more free time for this, sorry. By skimming the thread, This looks like something that should work out of the box, without much or any effort, At this point it almost feels simpler to build and cache these dependencies individually |
|
Here is our PR for moving to NuGet as caching backend. The token used to access the packages is stored as a secret in the repository, seems like a pragmatic solution to with no security issues. Management of token is described here |
|
I'm one of the maintainers of vcpkg. We are suggesting teams to switch to a NuGet-backend binary caching provider, your NuGet feed can still be hosted at GitHub if you use GitHub Packages. We can gladly assist with the transition if you reach to us at [email protected]. |
|
@vicroms |
from the comment microsoft/vcpkg#45073 (comment)
@vszakats Let me know what do you think. |
|
Thanks for everyone's interest in this. I've seen the recommendations, but none seem easy or a good fit for this Taking up the NuGet "ecosystem" on top of vcpkg seems like a large The NuGet method has mono as its dependency, to call two commands to set The manifest cache or actions/cache method has unclear invalidation On a wider picture, MSVC vcpkg jobs had caused a lot of grief since Speaking of individual dependencies, vcpkg builds the libpsl package in My point is, these jobs had caused issues we didn't see in other CI My question is if Microsoft is considering pushing pre-built binaries |
|
No one struggles as much and as hard with curl builds for Windows as @vszakats do. The primary idea behind curl's CI builds is to verify curl on different platforms with different dependencies and build combinations. It is not in our interest to be fancy or to favor any particular package management systems. In general it is just easier and more effective to avoid package managers in our CI - to just build a few dependencies from source and cache them individually. It gives us better control and a more stream-lined process. I'm all in favor of going the easiest route with the least friction. |
|
I can create a cache using gihub action cache mechanism with I created that mechanism in different repo. you can take a look. |
|
We started with this solution, and it wasn't good. It means rebuidling the whole cache whenever any dependency changes. These dependencies are deep, large and build slowly. Therefore it also means that we must extend the timeout for the job to an hour, which is a huge issue combined with Windows jobs routinely hanging, and forcing to wait for them to retry them manually. I think the Windows CI jobs have been more bearable since these large vcpkg builds are no longer done in them. I also believe Microsoft is in the perfect position to solve this problem like it was before breaking it unintentionally, In the meantime we are not in a hurry and the CI does its job fine as it is. |
My solution it similar to your past solution, but have a key difference. It will not rebuilding the whole cache whenever any dependency changes. I am not sure that microsoft/vcpkg team want to solve this problem as it was before, that why I am suggesting this solution. |
|
It doesn't solve the issue with hour+ long timeouts we would have to use for the initial What I'd like is not building dependencies from source in CI. Is there any reason why such (to me) essential feature is out of the scope for both I haven't had the time yet to try in production (the local test env is already in place It'd also make things easier if vcpkg could somehow be made (much) faster, and/or |
@vszakats perhaps you would be best served by the The Using this command, you can set up a workflow where you run
We provide methods to override how individual dependencies are built in the form of private registries and overlay ports; if you feel that the way we build a specific library in our registry is incorrect then you can also submit a PR to change the behavior. We are not experts on each individual library that is packaged so we rely on contributors that know better than us, we would love a submission that improves the situation for all users. Please let us know, if you would like us to explain the |
The unplanned dropping of the granular vcpkg binary cache indeed fell
into the cracks between Microsoft's various departments. The old method
is now official dropped, without replacement either on the vcpkg side or
the GitHub cache provider side.
Without a granular cache, vcpkg is impractical for builds larger than
a small dependency tree in CI, for performance reasons.
A granular cache is critical for CI use. Building dependencies is not
a goal of this CI, so a more desirable option would be pre-built binary
downloads. This would also allow keeping job timeouts low, which is
important for quick iteration in GHA when a flaky job requiring a manual
retry needs all other jobs to finish first. (GHA often disregards
step timeouts, which is another contributing factor here.)
Windows remains tested extensively with MSYS2, curl-for-win, and via
AppVeyor CI with MSVC + OpenSSL, and also in GHA via scaled back vcpkg
jobs that perform well without caching. What's lost is the recently
added Android OpenSSL build tests.
We may consider building/cachine important dependencies manually as in
GHA/linux-http3, and/or try integrating MSVC jobs with MSYS2 UCRT DLLs.
Ref: microsoft/vcpkg-tool#1662
Ref: microsoft/vcpkg#45073
Follow-up to cd0ec47 #17089
Follow-up to e3912f0 #17086
Follow-up to 15fb1dc #17069