feat: P0/P1/P2全部功能 — 四层泳道/视角切换/KPI看板/预警/差异反打/预算/知识面板/回顾会/情景预测/Excel导入/角色权限

This commit is contained in:
Hermes CI Fix
2026-07-12 17:46:08 +08:00
parent cdf00efd69
commit ee25d5fa1d
8871 changed files with 1778433 additions and 0 deletions
+63
View File
@@ -0,0 +1,63 @@
when:
- branch: main
event: push
variables:
- &ssh_setup |
apk add --no-cache openssh-client rsync
mkdir -p ~/.ssh
echo "$SSH_DEPLOY_KEY" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/id_ed25519
ssh-keyscan -H git.sxbh.ltd >> ~/.ssh/known_hosts
chmod 644 ~/.ssh/known_hosts
steps:
frontend-install:
image: node:20-alpine
commands:
- apk add --no-cache git
- cd frontend
- npm install -g pnpm
- pnpm install
when:
- path: frontend/**
frontend-build:
image: node:20-alpine
commands:
- cd frontend
- npm install -g pnpm
- pnpm install
- pnpm build
when:
- path: frontend/**
frontend-deploy:
image: alpine:latest
secrets:
- SSH_DEPLOY_KEY
commands:
- *ssh_setup
- rsync -avz --delete frontend/dist/ root@git.sxbh.ltd:/var/www/cma/
- ssh root@git.sxbh.ltd 'nginx -s reload || systemctl reload nginx'
when:
- path: frontend/**
backend-deploy:
image: alpine:latest
secrets:
- SSH_DEPLOY_KEY
commands:
- *ssh_setup
- ssh root@git.sxbh.ltd '
cd /root/cma-management &&
git pull origin main &&
cd backend &&
pip install -r requirements.txt --quiet --no-cache-dir &&
pkill -f uvicorn 2>/dev/null
sleep 2
cd /root/cma-management/backend &&
nohup python3 -m uvicorn app.main:app --host 0.0.0.0 --port 8010 > /var/log/cma-backend.log 2>&1 &
'
when:
- path: backend/**