Laravel版本:8.75
composer update
In CaBundle.php line 133:
tempnam(): file created in the system's temporary directory
require [--dev] [--dry-run] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--fixed] [--no-suggest] [--no-progress] [--no-update] [--no-install] [--update-no-dev] [-w|--update-with-dependencies] [-W|--update-with-all-dependencies] [--with-dependencies] [--with-all-dependencies] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--] [<packages>...]
两者的结果相同:
composer update
composer install
现在我发现问题是由php.ini sys_temp_dir引起的
默认值
;sys_temp_dir = "/tmp"
上次我换到这个,可是我忘了我为什么这样做了。
sys_temp_dir = "C:\windows\Temp"
这也会引起问题
sys_temp_dir = "tmp"
我们应该在php.ini中设置sys_temp_dir吗?
1条答案
按热度按时间des4xlb01#
此问题有两种可能的解决方案。这是由于对文件夹C:\Windows\Temp的访问权限造成的。请应用以下两种解决方案之一:
1.可以在以管理员模式see here打开的终端中启动命令
1.更改所有PC用户对Windows临时文件夹C:\Windows\Temp的权限
see here