chore: remove unused Docker and localization files

- Deleted Dockerfiles for backend and frontend, along with the associated Nginx configuration and localization debugging script, to streamline the project structure and eliminate unnecessary files.
This commit is contained in:
bridge
2026-02-03 21:44:17 +08:00
parent f2c4b5609d
commit c2c1ce46d1
5 changed files with 3 additions and 36 deletions

View File

@@ -1,33 +0,0 @@
import sys
import os
from pathlib import Path
# Add src to sys.path
sys.path.append(os.getcwd())
from src.classes.language import language_manager
from src.i18n import t, reload_translations, _get_translation, _get_current_lang
print(f"Initial Language: {_get_current_lang()}")
# Try translating without setting language (should be zh-CN by default per LanguageManager)
print(f"Default 'History' translation: {t('History')}")
# Explicitly set to zh-CN
print("Setting language to zh-CN...")
language_manager.set_language("zh-CN")
print(f"Current Language: {_get_current_lang()}")
print(f"Translated 'History': {t('History')}")
print(f"Translated 'Killed by {{killer}}': {t('Killed by {killer}', killer='张三')}")
# Check internal translation object
trans = _get_translation()
print(f"Translation Object: {trans}")
if trans:
print(f"Info: {trans.info()}")
# Check file paths
locale_dir = Path("src/i18n/locales")
mo_path = locale_dir / "zh_CN" / "LC_MESSAGES" / "messages.mo"
print(f"MO file exists: {mo_path.exists()}")
print(f"MO file absolute path: {mo_path.absolute()}")

View File

@@ -22,7 +22,7 @@ FROM nginx:alpine
COPY --from=builder /app/dist /usr/share/nginx/html COPY --from=builder /app/dist /usr/share/nginx/html
# 复制 Nginx 配置 # 复制 Nginx 配置
COPY nginx.conf /etc/nginx/conf.d/default.conf COPY deploy/nginx.conf /etc/nginx/conf.d/default.conf
# 暴露端口 # 暴露端口
EXPOSE 80 EXPOSE 80

View File

@@ -5,7 +5,7 @@ services:
backend: backend:
build: build:
context: . context: .
dockerfile: Dockerfile.backend dockerfile: deploy/Dockerfile.backend
container_name: cultivation-backend container_name: cultivation-backend
ports: ports:
- "8002:8002" - "8002:8002"
@@ -25,7 +25,7 @@ services:
frontend: frontend:
build: build:
context: . context: .
dockerfile: Dockerfile.frontend dockerfile: deploy/Dockerfile.frontend
container_name: cultivation-frontend container_name: cultivation-frontend
ports: ports:
- "8123:80" - "8123:80"