diff --git a/application/index/controller/admin/System.php b/application/index/controller/admin/System.php index 20de4118..70ff3768 100644 --- a/application/index/controller/admin/System.php +++ b/application/index/controller/admin/System.php @@ -119,25 +119,6 @@ class System extends Base $isBackup && $upgrade->backup($backup); // 备份原系统 - // 复制 env 文件 - $config = \config('database.'); - $env = str_ireplace([ - '{hostname}', - '{database}', - '{username}', - '{password}', - '{hostport}', - ], [ - $config['hostname'], - $config['database'], - $config['username'], - $config['password'], - $config['hostport'], - ], @file_get_contents($path . '.env.example')); - if (!@file_put_contents($path . '.env', $env)) { - throw new \Exception('配置文件写入失败'); - } - // 创建安装锁文件 if (!@fopen($path . 'application/install.lock', 'w')) { throw new \Exception('安装锁文件创建失败');