feat:GCS 환경변수(.env) 기반 설정 지원
- config/gcs.php 추가: 환경변수 기반 설정 - GoogleCloudStorageService 우선순위 변경: 1. DB 설정 (UI 오버라이드용) 2. 환경변수 (.env) - 기본 3. 레거시 파일 (fallback) - .env.example에 GCS 설정 추가 - 서버 배포 시 .env만 설정하면 DB 설정 불필요 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
21
config/gcs.php
Normal file
21
config/gcs.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Google Cloud Storage 설정
|
||||
*
|
||||
* 우선순위:
|
||||
* 1. DB 설정 (ai_configs 테이블) - UI에서 오버라이드 가능
|
||||
* 2. 환경변수 (.env)
|
||||
* 3. 레거시 파일 (/sales/apikey/)
|
||||
*/
|
||||
|
||||
return [
|
||||
// 버킷 이름
|
||||
'bucket_name' => env('GCS_BUCKET_NAME'),
|
||||
|
||||
// 서비스 계정 파일 경로
|
||||
'service_account_path' => env('GCS_SERVICE_ACCOUNT_PATH', '/var/www/sales/apikey/google_service_account.json'),
|
||||
|
||||
// DB 설정 사용 여부 (false면 .env만 사용)
|
||||
'use_db_config' => env('GCS_USE_DB_CONFIG', true),
|
||||
];
|
||||
Reference in New Issue
Block a user