Repository navigation
feat: v0.15.1 — Ollama 本地模型接入、AI 处理器重构与认证体系增强 #1
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy AI Gateway | |
| on: | |
| push: | |
| branches: [master] | |
| paths: ['server/**'] | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Build and push Docker image | |
| run: | | |
| cd server | |
| docker build -t ai-gateway:${{ github.sha }} . | |
| - name: Deploy to server | |
| uses: appleboy/ssh-action@v1 | |
| with: | |
| host: ${{ secrets.SERVER_HOST }} | |
| username: ${{ secrets.SERVER_USER }} | |
| key: ${{ secrets.SSH_PRIVATE_KEY }} | |
| script: | | |
| cd /opt/keban | |
| docker-compose pull | |
| docker-compose up -d --force-recreate | |
| sleep 10 | |
| curl -f http://localhost:8000/health || (docker-compose rollback && exit 1) |