diff --git a/nginx/main-page.conf b/nginx/main-page.conf deleted file mode 100644 index b4117f4..0000000 --- a/nginx/main-page.conf +++ /dev/null @@ -1,23 +0,0 @@ -server { - listen 80; - server_name dbx.no1king.freeddns.org; - - return 301 https://$host$request_uri; -} - -server { - listen 443 ssl http2; - server_name dbx.no1king.freeddns.org; - - ssl_certificate /etc/letsencrypt/live/dbx.no1king.freeddns.org/fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live/dbx.no1king.freeddns.org/privkey.pem; - - location / { - proxy_pass http://127.0.0.1:8000; - proxy_http_version 1.1; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto $scheme; - } -} diff --git a/push-gitea.bat b/push-gitea.bat deleted file mode 100644 index 5c0ea0e..0000000 --- a/push-gitea.bat +++ /dev/null @@ -1,72 +0,0 @@ -@echo off -cd /d "%~dp0" - -echo. -echo [1/2] Checking for sensitive files... -echo. - -set FOUND=0 - -:: git? ??? ??(tracked)?? ?? ?? ?? -for %%F in ( - .env - .env.local - .env.production - .env.secret -) do ( - git ls-files --error-unmatch "%%F" >nul 2>&1 - if not errorlevel 1 ( - echo [ERROR] Sensitive file is tracked by git: %%F - set FOUND=1 - ) -) - -:: ??? ?? ?? ??? git? ????? ?? -for %%P in ( - *.pem *.key *.p12 *.pfx id_rsa id_ed25519 - *secret* *password* *credential* *token* *apikey* *api_key* - db.conf database.conf -) do ( - git ls-files "%%P" 2>nul | findstr /r "." >nul 2>&1 - if not errorlevel 1 ( - echo [ERROR] Sensitive file pattern tracked by git: %%P - set FOUND=1 - ) -) - -if %FOUND%==1 ( - echo. - echo ============================================================ - echo PUSH BLOCKED: Sensitive file found in git. - echo. - echo Remove it with: - echo git rm --cached ^ - echo git commit -m "remove sensitive file" - echo. - echo Then add it to .gitignore to prevent future accidents. - echo ============================================================ - echo. - pause - exit /b 1 -) - -echo No sensitive files detected. Safe to push. -echo. - -echo [2/2] Pushing to Gitea... -echo https://gitea.no1king.freeddns.org/king/dbx-main.git -echo. - -git push -u origin master - -if %errorlevel%==0 ( - echo. - echo [OK] Push complete. - echo https://gitea.no1king.freeddns.org/king/dbx-main - echo. -) else ( - echo. - echo [ERROR] Push failed. Check your credentials or network. - echo. -) -pause \ No newline at end of file diff --git a/run-local.bat b/run-local.bat deleted file mode 100644 index 3693bb6..0000000 --- a/run-local.bat +++ /dev/null @@ -1,63 +0,0 @@ -@echo off -cd /d "%~dp0" - -set PROJECT=dbx-main -set COMPOSE=docker compose -p %PROJECT% -f docker-compose.local.yml - -if "%1"=="stop" goto STOP -if "%1"=="logs" goto LOGS -if "%1"=="ps" goto PS -if "%1"=="restart" goto RESTART - -:START -if not exist ".env.local" ( - echo. - echo [ERROR] .env.local not found. - echo Copy .env.local.example and fill in the values: - echo. - echo copy .env.local.example .env.local - echo. - pause - exit /b 1 -) -echo. -echo Starting DBX Main Page (local)... -echo. -%COMPOSE% up --build -d -if %errorlevel%==0 ( - echo. - echo [OK] Running at http://localhost:8080 - echo. - echo Logs : run-local.bat logs - echo Stop : run-local.bat stop - echo. -) -pause -exit /b - -:STOP -echo. -echo Stopping container... -%COMPOSE% down -echo. -pause -exit /b - -:LOGS -%COMPOSE% logs -f -exit /b - -:PS -echo. -%COMPOSE% ps -echo. -pause -exit /b - -:RESTART -echo. -echo Restarting... -%COMPOSE% restart -echo. -pause -exit /b \ No newline at end of file diff --git a/run-local.ps1 b/run-local.ps1 deleted file mode 100644 index 7b6acec..0000000 --- a/run-local.ps1 +++ /dev/null @@ -1,52 +0,0 @@ -# DBX 메인 페이지 — 로컬 실행 스크립트 -# 사용법: .\run-local.ps1 [명령어] -# -# .\run-local.ps1 → 시작 (코드 변경 시 자동 재빌드) -# .\run-local.ps1 stop → 중지 -# .\run-local.ps1 logs → 로그 보기 -# .\run-local.ps1 ps → 상태 확인 -# .\run-local.ps1 restart → 재시작 - -$PROJECT = "dbx-main" -$COMPOSE = "docker compose -p $PROJECT -f docker-compose.local.yml" - -switch ($args[0]) { - "stop" { - Write-Host "컨테이너 중지 중..." -ForegroundColor Yellow - Invoke-Expression "$COMPOSE down" - } - "logs" { - Invoke-Expression "$COMPOSE logs -f" - } - "ps" { - Invoke-Expression "$COMPOSE ps" - } - "restart" { - Write-Host "재시작 중..." -ForegroundColor Yellow - Invoke-Expression "$COMPOSE restart" - } - default { - # .env.local 없으면 안내 후 종료 - if (-not (Test-Path ".env.local")) { - Write-Host "" - Write-Host "❌ .env.local 파일이 없습니다." -ForegroundColor Red - Write-Host " .env.local.example 을 복사하여 값을 채워주세요:" -ForegroundColor Yellow - Write-Host " copy .env.local.example .env.local" -ForegroundColor Cyan - Write-Host "" - exit 1 - } - - Write-Host "" - Write-Host "🚀 DBX 메인 페이지 로컬 시작..." -ForegroundColor Cyan - Invoke-Expression "$COMPOSE up --build -d" - - if ($LASTEXITCODE -eq 0) { - Write-Host "" - Write-Host "✅ 실행 중 → http://localhost:8080" -ForegroundColor Green - Write-Host "" - Write-Host " 로그 보기 : .\run-local.ps1 logs" -ForegroundColor Gray - Write-Host " 중지 : .\run-local.ps1 stop" -ForegroundColor Gray - Write-Host "" - } - } -}