Я пытаюсь composer требовать barryvdh / laravel -dompdf. Но я получил:
E:\wamp64\www\laravel\Bugler>composer require barryvdh/laravel-dompdf You are running Composer with SSL/TLS protection disabled. The "https://repo.packagist.org/packages.json" file could not be downloaded: php_network_getaddresses: getaddrinfo failed: No such host is known. failed to open stream: php_network_getaddresses: getaddrinfo failed: No such host is known. https://repo.packagist.org could not be fully loaded, package information was loaded from the local cache and may be out of date [Composer\Downloader\TransportException] The "https://repo.packagist.org/p/barryvdh/laravel-dompdf%24121356f3b13be1ea852a1b1d7ee643fe8af75206dd35d9e62998d63 5a75f929c.json" file could not be downloaded: php_network_getaddresses: getaddrinfo failed: No such host is known. failed to open stream: php_network_getaddresses: getaddrinfo failed: No such host is known. require [--dev] [--prefer-source] [--prefer-dist] [--fixed] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--update-with-all-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] [<packages>]...
Может ли кто-нибудь мне помочь? Я также пытаюсь решить эту проблему.
php artisan cache:clear
php artisan config:cache
Удалите файл composer.lock в каталоге вашего проекта и выполните команду ниже:
composer.lock
composer install
Или вы можете попробовать выполнить следующую команду:
composer require barryvdh/laravel-dompdf:0.8.2
Подобная проблема уже указана в Composer github repository
Composer github repository
Эта проблема возникает из-за неправильной конфигурации прокси. Проверьте конфигурацию прокси.
Также, если вы используете какой-либо антивирус, отключите его и повторите попытку
https://github.com/composer/composer/issues/6891
Попробуйте это
composer update dompdf/dompdf
затем
composer require barryvdh/laravel-dompdf