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

Add mirror support for vcpkg_download_distfile #58

Closed
ghost opened this issue Sep 21, 2016 · 5 comments
Closed

Add mirror support for vcpkg_download_distfile #58

ghost opened this issue Sep 21, 2016 · 5 comments

Comments

@ghost
Copy link

ghost commented Sep 21, 2016

port files refer directly to URLs of external websites, e.g. for Curl: "https://curl.haxx.se/download/curl-7.48.0.tar.bz2". That is very brittle, in that if that site were to go down, suddenly potentially a lot of programmers can't build their code.

That may be an acceptable trade-off for individual programmers, but for a larger organization having the teams ability to work depend on many external sites may be a deal breaker, unless there was some easy way to (locally?) cache things.

@Telokis
Copy link
Contributor

Telokis commented Sep 21, 2016

Do you think about a local cache ? Like downloading all libraries and ship them along with vcpkg ?
What about mirror downloads ?

@ras0219-msft
Copy link
Contributor

ras0219-msft commented Sep 21, 2016

I think mirrors are definitely a great idea.

Additionally, we already first check the downloads\ folder before making external contact so you can (ahead of time) download and store all the source code you depend on, then copy them to downloads\ before running vcpkg install curl.

@ras0219-msft ras0219-msft changed the title Have a caching strategy Add mirror support for vcpkg_download_distfile Sep 21, 2016
@Telokis
Copy link
Contributor

Telokis commented Sep 24, 2016

I'm working on this issue right now.
If the file is successfully downloaded but I get the wrong hash, should I try a mirror or print a FATAL_ERROR ?

@Telokis
Copy link
Contributor

Telokis commented Sep 24, 2016

In #83 I opted for the second option: once a file successed to download, I never try to download anymore, even if the HASH doesn't match.

strega-nil added a commit to strega-nil/vcpkg that referenced this issue May 5, 2021
strega-nil added a commit to strega-nil/vcpkg that referenced this issue May 5, 2021
The following PRs are included:

* hopefully fix crash in constraints (microsoft#60)
* [vcpkg] allow --version to check the version (microsoft#50)
* Remove baseline warning (microsoft#27)
* [git] always pass autocrlf=false (microsoft#58)
* ignore QtCreator CMake project files (microsoft#54)
* ignore .DS_store files (microsoft#53)
* [vcpkg] x-add-version now also checks if the manifest file is properly formatted (microsoft#43)
* hopefully fix ci issue microsoft#16773 (microsoft#34)
* Add docs to set VCPKG_ROOT to run tests (microsoft#45)
* [vcpkg] x-add-version improve speed by calling get_builtin_baseline only once (microsoft#44)
* add clang-format version to format-cxxcode (microsoft#41)
* [vcpkg] Introduce experimental workaround X_VCPKG_NUGET_ID_PREFIX (microsoft#40)
* [supports] Add `native` identifier expression and x-check-support command (microsoft#29)
* [metrics] Split reporting of installs into name:triplet (microsoft#39)
* [vcpkg] Improve error when accessing missing feature (microsoft#38)
* [vcpkg] Allow shallow git registries (microsoft#37)
* Disable git autocrlf when archiving tree (microsoft#36)
* Use only named packages from extra registries (microsoft#35)
* [registries] add metrics (microsoft#30)
* Add vcpkg policy cmake helper port support (microsoft#17)
* [osx] add support for rosetta (microsoft#23)
* don't build tls12-download unless it's needed (microsoft#33)
* Add new telemetry points for versioning (microsoft#21)
* add cmake_minimum_required to vcpkg_tags (microsoft#25)
* [x-add-versions] Perform atomic replacement of versioning files (microsoft#28)
* [tools] support gsutil (microsoft#19)
* add CUDA 11.1 and 11.2 to KEEP_ENV_VARS defaults (microsoft#26)
* Add finite timeout on CURL metrics endpoint. (microsoft#22)
* fix UB in make_error_code(utf8_errc) (microsoft#18)
@votecoffee
Copy link

When I pre-download files, sometimes I have to add a prefix like 'msys-'. If you look in the downloads temp folder, it will create an empty file while attempting to download and this will help give a clue of the filename it expects, which is not always the same as the filename it is downloading.

dempo93 pushed a commit to dempo93/vcpkg that referenced this issue Aug 23, 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

3 participants