Skip to content

Retry / switch to source build on connection errors #792

Description

@shyim

What are you trying to do?
Last night several docker image builds failed due to GitHub reachability,

   > [frankenphp-8-2 linux/arm64 stage-0 3/5] RUN --mount=type=bind,from=ghcr.io/php/pie:bin,source=/pie,target=/usr/local/bin/pie <<EOF (set -e...):
  67.99 ✅ PIE package phpredis/phpredis (redis) is already installed and verified.
  68.86 
  68.87 In CouldNotDetermineDownloadUrlMethod.php line 31:
  68.87                                                                                
  68.87   Could not download kjdev/zstd using pre-packaged-source method: Could not a  
  68.87   uthenticate against github.com                                               
  68.87                                                                                
  68.87 
  68.87 install [-j|--make-parallel-jobs MAKE-PARALLEL-JOBS] [--skip-enable-extension] [--force] [--suppress-download-url-method SUPPRESS-DOWNLOAD-URL-METHOD] [-d|--working-dir WORKING-DIR] [--with-php-config WITH-PHP-CONFIG] [--with-php-path WITH-PHP-PATH] [--with-phpize-path WITH-PHPIZE-PATH] [--no-cache] [--allow-non-interactive-project-install] [--no-dev] [--select SELECT] [--auto-install-build-tools] [--no-build-tools-check] [--auto-install-system-dependencies] [--no-system-dependencies-check] [--from-lock] [--] [<requested-package-and-version>...]

What platform, and PIE version are you using?
(add the output of pie show -v, and information about which OS you're using etc.)

Steps to reproduce the issue

Install zstd extension through Pie inside an

What do you expect to happen?
Retry or fallback to source download

What is actually happening
Pipeline failed could maybe worked with an source download

Complete logs/output
Complete error messages and/or logs, including stack traces (hint: use -v for verbose), but please redact sensitive information.

Anything else?
other information that might be helpful...

Activity

  1. shyim commented on Oct 26, 2026

    @shyim
    Author

    It's persistent, injecting COMPOSER_AUTH fixed it shopware/docker@b0af63a

    can we get back to an centralized server with proper caching and CDN? 😭

  2. self-assigned this
    on Oct 26, 2026
  3. added
    enhancementNew feature or request
    maintainer investigatingThis ticket is being investigated by maintainers. Please check with us before contributing PRs etc!
    on Oct 26, 2026
  4. added theissue type on Oct 26, 2026
  5. added this to the 1.6.0 milestone on Nov 3, 2026
  6. asgrim commented on Nov 3, 2026

    @asgrim
    Contributor

    This is actually already supported, but the specific extension you're trying has explicitly stated they only support pre-packaged-source:

    "download-url-method": "pre-packaged-source"
    

    https://github.com/kjdev/php-ext-zstd/blob/2dbc8f408c5ea191351dd6a1c226ef2d3eddd368/composer.json#L11

    This means that regardless, PIE will not try composer-default as a fallback, for this extension.

    I've added a test in #814 that shows this fallback behaviour would already work in PIE if composer-default was available for the extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestmaintainer investigatingThis ticket is being investigated by maintainers. Please check with us before contributing PRs etc!

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions