安装引导

This commit is contained in:
TL 2022-09-05 18:27:45 +08:00
parent ffa2c7d370
commit f94e780462
4 changed files with 4 additions and 11 deletions

View File

@ -94,13 +94,15 @@ class EnvironmentManager
{
$results = trans('installer::installer_messages.environment.success');
$app_url = $_SERVER['APP_URL'];
$envFileData =
'APP_NAME=\''.$request->app_name."'\n".
'APP_ENV='.$request->environment."\n".
'APP_KEY='.'base64:'.base64_encode(Str::random(32))."\n".
'APP_DEBUG=true'."\n".
'APP_LOG_LEVEL='.$request->app_log_level."\n".
'APP_URL='.$request->app_url."\n\n".
'APP_URL='.$app_url."\n\n".
'DB_CONNECTION='.$request->database_connection."\n".
'DB_HOST='.$request->database_hostname."\n".
'DB_PORT='.$request->database_port."\n".

View File

@ -23,6 +23,7 @@ class InstallerServiceProvider extends ServiceProvider
Schema::defaultStringLength(191);
$this->mergeConfigFrom(__DIR__ . '/../config.php', 'installer');
$this->mergeConfigFrom(__DIR__ . '/../../Config/beike.php', 'beike');
$this->loadViewsFrom(__DIR__ . '/../Views', 'installer');

View File

@ -20,15 +20,6 @@
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<div class="row gx-4 gy-3">
<div class="col-sm-6">
<label class="form-label">
{{ trans($entry_key . 'app_url_label') }}
</label>
<input class="form-control {{ $errors->has('app_url') ? 'is-invalid' : '' }}" name="app_url"
value="{{ old('app_url', '') }}" required placeholder="{{ trans($entry_key . 'app_url_placeholder') }}">
<span class="invalid-feedback"
role="alert">{{ $errors->has('app_url') ? $errors->first('app_url') : __('common.error_required', ['name' => trans($entry_key . 'app_url_label')]) }}</span>
</div>
<div class="col-sm-6">
<label class="form-label">
{{ trans($entry_key . 'db_connection_label') }}

View File

@ -60,7 +60,6 @@ return [
'environment' => [
'form' => [
'rules' => [
'app_url' => 'required|url',
'database_connection' => 'required|string|max:50',
'database_hostname' => 'required|string|max:50',
'database_port' => 'required|numeric',