1
0
mirror of https://github.com/laravel/valet.git synced 2026-02-04 08:10:07 +01:00

Create php-memory-limits.ini only one time

Change how the php-memory-limits.ini is managed because when changed between PHP versions all the configuration added previously is overrided and it a waste of time if you work with several PHP versions during the day
This commit is contained in:
Marc Rodriguez
2025-06-18 11:27:56 +02:00
committed by GitHub
parent 4fa47a8a66
commit 10947733a2

View File

@@ -82,10 +82,12 @@ public function createConfigurationFiles(string $phpVersion): void
$destDir = dirname(dirname($fpmConfigFile)).'/conf.d';
$this->files->ensureDirExists($destDir, user());
if (!file_exists($destDir.'/php-memory-limits.ini')) {
$this->files->putAsUser(
$destDir.'/php-memory-limits.ini',
$this->files->getStub('php-memory-limits.ini')
);
}
$contents = str_replace(
['VALET_USER', 'VALET_HOME_PATH'],