init: dbx-corm 프로젝트 Docker 기반 마이그레이션

주요 변경사항:
- DB 접속정보를 환경변수(.env) 방식으로 분리
- orderlist_app → orderlist_db 변경 (main.py, routers/returns.py)
- 네이버/카페24 API 키도 환경변수로 분리
- Dockerfile / docker-compose.yml 작성 (외부 PostgreSQL 네트워크 연결)
- .gitignore: 민감파일(.env, cafe24_tokens.json, manual-ordering.json) 제외
- 불필요 파일 정리 (venv, __pycache__, 일회성 스크립트, xlsx 등)
- README.md / .env.example / push_to_gitea.bat 추가

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-24 15:11:34 +09:00
commit 6e438344d0
20 changed files with 8179 additions and 0 deletions
+101
View File
@@ -0,0 +1,101 @@
@echo off
chcp 65001 > nul
cd /d "%~dp0"
echo.
echo =========================================
echo DBX CORM - Gitea Push
echo https://gitea.no1king.freeddns.org/king/dbx-corm
echo =========================================
echo.
REM 민감 파일 추적 확인
echo [1/5] Checking for sensitive files...
set FOUND=0
for %%F in (
.env
cafe24_tokens.json
manual-ordering.json
) 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
)
)
if %FOUND%==1 (
echo.
echo PUSH BLOCKED. Remove with:
echo git rm --cached ^<filename^>
echo git commit -m "remove sensitive file"
echo.
pause
exit /b 1
)
echo OK.
echo.
REM Git 상태
echo [2/5] Git status:
echo -----------------------------------------
git status -s
echo -----------------------------------------
echo.
REM 변경사항 없으면 종료
git diff --quiet
set DIFF1=%errorlevel%
git diff --cached --quiet
set DIFF2=%errorlevel%
git ls-files --others --exclude-standard | findstr /r "." >nul
set DIFF3=%errorlevel%
if "%DIFF1%"=="0" if "%DIFF2%"=="0" if not "%DIFF3%"=="0" (
echo No changes to commit. Exiting.
pause
exit /b 0
)
REM 스테이징
echo [3/5] Staging files...
git add -A
echo OK.
echo.
REM 커밋 메시지 입력
echo [4/5] Enter commit message:
set /p MSG=^>^>
if "%MSG%"=="" (
echo [ERROR] Empty commit message.
pause
exit /b 1
)
git commit -m "%MSG%"
if errorlevel 1 (
echo [ERROR] Commit failed.
pause
exit /b 1
)
echo.
REM Push
echo [5/5] Pushing to Gitea...
git push -u origin master
if errorlevel 1 (
git push -u origin main
)
if %errorlevel%==0 (
echo.
echo =========================================
echo [OK] Push complete!
echo https://gitea.no1king.freeddns.org/king/dbx-corm
echo =========================================
) else (
echo.
echo [ERROR] Push failed. Check credentials or network.
)
echo.
pause