Docker-compose によるlaravelの環境構築のため、
【初心者向け】20分でLaravel開発環境を爆速構築するDockerハンズオン
https://qiita.com/ucan-lab/items/56c9dc3cf2e6762672f4
の、※Laravelをインストールする
app コンテナに入り、Laravelをインストール
welcomeページが表示されるかを参考し
[mac] $ docker-compose exec app bash
[app] $ composer create-project --prefer-dist "laravel/laravel=8.*" .
[app] $ php artisan -V
Laravel Framework 8.0.0
と入力しましたが、途中(?)で下記のようなエラーがでてしまいました。
ErrorException]
copy(): write of 8192 bytes failed with errno=14 Bad address ←エラー内容
composer create-project --prefer-dist "laravel/laravel=7.*" .
としましたが結果は変わらず…
調べましたが、エラー内容が分かりませんでした。
このまま、今回インストールしたlaravelは使用できるのでしょうか❓
エラー内容と、対策を教えていただきたいです。
よろしくお願いします。
前提・実現したいこと
ここに質問の内容を詳しく書いてください。
(例)PHP(CakePHP)で●●なシステムを作っています。
■■な機能を実装中に以下のエラーメッセージが発生しました。
発生している問題・エラーメッセージ
ErrorException] copy(): write of 8192 bytes failed with errno=14 Bad address
該当のソースコード
docker-laravel-handson % docker-compose exec app bash root@b9dbe9e531d3:/work# composer create-project --prefer-dist "laravel/laravel=8.*" . Creating a "laravel/laravel=8.*" project at "./" php artisInstalling laravel/laravel (v8.0.1) - Installing laravel/laravel (v8.0.1): DoDownloading (100%) Created project in /work/. > @php -r "file_exists('.env') || copy('.env.example', '.env');" Loading composer repositories with package information Updating dependencies (including require-dev) Package operations: 106 installs, 0 updates, 0 removals - Installing voku/portable-ascii (1.5.3): Downloading (100%) - Installing symfony/polyfill-php80 (v1.18.1): Downloading (100%) - Installing symfony/polyfill-mbstring (v1.18.1): Downloading (100%) - Installing symfony/polyfill-ctype (v1.18.1): Downloading (100%) - Installing phpoption/phpoption (1.7.5): Downloading (100%) - Installing graham-campbell/result-type (v1.0.1): Downloading (100%) - Installing vlucas/phpdotenv (v5.2.0): Downloading (100%) - Installing symfony/css-selector (v5.1.5): Downloading (100%) - Installing tijsverkoyen/css-to-inline-styles (2.2.3): Downloading (100%) - Installing symfony/var-dumper (v5.1.5): Downloading (100%) - Installing symfony/deprecation-contracts (v2.2.0): Downloading (100%) - Installing symfony/routing (v5.1.5): Downloading (100%) - Installing symfony/process (v5.1.5): Downloading (100%) - Installing symfony/polyfill-php72 (v1.18.1): Downloading (100%) - Installing paragonie/random_compat (v9.99.99): Downloading (100%) - Installing symfony/polyfill-php70 (v1.18.1): Downloading (100%) - Installing symfony/polyfill-intl-normalizer (v1.18.1): Downloading (100%) - Installing symfony/polyfill-intl-idn (v1.18.1): Downloading (100%) - Installing symfony/mime (v5.1.5): Downloading (100%) - Installing symfony/polyfill-intl-grapheme (v1.18.1): Downloading (100%) - Installing symfony/string (v5.1.5): Downloading (100%) - Installing phpdocumentor/reflection-common (2.2.0): Downloading (100%) - Installing webmozart/assert (1.9.1): Downloading (100%) - Installing phpdocumentor/type-resolver (1.4.0): Downloading (100%) - Installing phpdocumentor/reflection-docblock (5.2.2): Downloading (100%) - Installing psr/log (1.1.3): Downloading (100%) - Installing symfony/polyfill-php73 (v1.18.1): Downloading (100%) - Installing symfony/http-foundation (v5.1.5): Downloading (100%) - Installing psr/event-dispatcher (1.0.0): Downloading (100%) - Installing symfony/event-dispatcher-contracts (v2.2.0): Downloading (100%) - Installing symfony/event-dispatcher (v5.1.5): Downloading (100%) - Installing symfony/error-handler (v5.1.5): Downloading (100%) - Installing symfony/http-kernel (v5.1.5): Downloading (100%) - Installing psr/container (1.0.0): Downloading (100%) - Installing symfony/finder (v5.1.5): Downloading (100%) - Installing symfony/service-contracts (v2.2.0): Downloading (100%) - Installing symfony/console (v5.1.5): Downloading (100%) - Installing symfony/polyfill-iconv (v1.18.1): Downloading (100%) - Installing doctrine/lexer (1.2.1): Downloading (100%) - Installing egulias/email-validator (2.1.21): Downloading (100%) - Installing swiftmailer/swiftmailer (v6.2.3): Downloading (100%) - Installing brick/math (0.9.1): Downloading (100%) - Installing ramsey/collection (1.1.1): Downloading (100%) - Installing ramsey/uuid (4.1.1): Downloading (100%) - Installing psr/simple-cache (1.0.1): Downloading (100%) - Installing opis/closure (3.5.7): Downloading (100%) - Installing symfony/translation-contracts (v2.2.0): Downloading (100%) - Installing symfony/translation (v5.1.5): Downloading (100%) - Installing nesbot/carbon (2.40.0): Downloading (100%) [ErrorException] copy(): write of 8192 bytes failed with errno=14 Bad address create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--ignore-platform-reqs] [--] [<package>] [<directory>] [<version>] root@b9dbe9e531d3:/work# php artisan -v [22-Sep-2020 04:40:29 Asia/Tokyo] PHP Warning: require(/work/vendor/autoload.php): failed to open stream: No such file or directory in /work/artisan on line 18 Warning: require(/work/vendor/autoload.php): failed to open stream: No such file or directory in /work/artisan on line 18 [22-Sep-2020 04:40:29 Asia/Tokyo] PHP Fatal error: require(): Failed opening required '/work/vendor/autoload.php' (include_path='.:/usr/local/lib/php') in /work/artisan on line 18 Fatal error: require(): Failed opening required '/work/vendor/autoload.php' (include_path='.:/usr/local/lib/php') in /work/artisan on line 18
試したこと
ここに問題に対して試したことを記載してください。
補足情報(FW/ツールのバージョンなど)
アクセスすると以下のエラーメッセージが表示されてしまいます。
Warning: require(/work/public/../vendor/autoload.php): failed to open stream: No such file or directory in /work/public/index.php on line 34
Fatal error: require(): Failed opening required '/work/public/../vendor/autoload.php' (include_path='.:/usr/local/lib/php') in /work/public/index.php on line 34
あなたの回答
tips
プレビュー