Skip to content
GitHub

Configure PHP

Point Composer's Packagist repository at Depsilo's /composer/ route and understand the post-451 dist fallback.

BEFOREhttps://repo.packagist.org
AFTERhttp://localhost:23333/composer/

Composer points Packagist at Depsilo through repository configuration; composer.json and composer.lock stay unchanged.

终端窗口
composer config -g repo.packagist composer http://localhost:23333/composer/
# Plain HTTP only:
composer config -g secure-http false
composer diagnose

-g writes user-level configuration. Drop it to affect only the current project, which is a good way to verify one repository first.

  1. Check that the instance is ready

    终端窗口
    curl -fsS http://localhost:23333/ready
  2. Install dependencies again

    终端窗口
    composer install --no-interaction
  3. Confirm the traffic in Admin

    Check the /composer/ requests and cache results in Access logs.

Only for plain HTTP. Remove secure-http false when Depsilo is served over valid HTTPS.

Configure the private repository and its authentication separately; Depsilo does not store Composer credentials. Authenticated upstream responses do not enter the shared cache.