fix: manageSqlDatabase provisionMySQL 在 MySQL 未开通时失败:工具内部先调用 DescribeMySQLClusterDetail,因实例不存在而报错,未实际发起创建请求 #1402
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: Publish MCP Package to pkg.pr.new | |
| on: | |
| # 在推送和PR时触发 | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| # 也支持手动触发 | |
| workflow_dispatch: | |
| jobs: | |
| # 构建和发布到pkg.pr.new | |
| build-and-publish: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Enable corepack | |
| run: corepack enable | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| cache: 'npm' | |
| cache-dependency-path: 'mcp/package-lock.json' | |
| - name: Install dependencies | |
| run: | | |
| cd mcp | |
| npm ci | |
| - name: Build package | |
| run: | | |
| cd mcp | |
| npm run build | |
| - name: Test package | |
| run: | | |
| cd mcp | |
| npm run test | |
| env: | |
| TENCENTCLOUD_SECRETID: ${{ secrets.TENCENTCLOUD_SECRETID }} | |
| TENCENTCLOUD_SECRETKEY: ${{ secrets.TENCENTCLOUD_SECRETKEY }} | |
| CLOUDBASE_ENV_ID: ${{ secrets.CLOUDBASE_ENV_ID }} | |
| - name: Publish to pkg.pr.new | |
| run: | | |
| cd mcp | |
| npx pkg-pr-new publish --comment=off |