feat: add Docker support with multi-stage build and CI/CD workflow
All checks were successful
Build and Push Docker Image / build (push) Successful in 1m42s

- Introduced Dockerfile for multi-stage build process using Node.js and Nginx.
- Added .dockerignore to exclude unnecessary files from Docker context.
- Created nginx.conf for server configuration, including gzip compression and SPA routing.
- Implemented Gitea CI/CD workflow for building and pushing Docker images on version tags.
This commit is contained in:
typist
2025-10-27 22:32:54 +08:00
parent a1e2239458
commit 10bc8fe7cb
4 changed files with 220 additions and 0 deletions

62
.dockerignore Normal file
View File

@@ -0,0 +1,62 @@
# 依赖
node_modules
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# 构建产物
dist
dist-ssr
*.local
# 编辑器
.vscode
.idea
*.swp
*.swo
*~
# 操作系统
.DS_Store
Thumbs.db
# Git
.git
.gitignore
.gitattributes
# CI/CD
.gitea
.github
.gitlab-ci.yml
# Docker
Dockerfile
.dockerignore
docker-compose.yaml
docker-compose.*.yaml
compose*yaml
# 测试
coverage
.nyc_output
# 环境变量
.env
.env.local
.env.*.local
# 日志
logs
*.log
# 临时文件
tmp
temp
# 文档
README.md
LICENSE
*.md