0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

codex-actionでMCPサーバーを使用する

Posted at

codex-argsでconfigを上書きする形で設定します。

name: E2E Report
on:
  workflow_dispatch:
jobs:
  codex:
    runs-on: ubuntu-latest
    outputs:
      final_message: ${{ steps.run_codex.outputs.final-message }}
    steps:
      - name: Install MCP Server
        run: npm install -g chrome-devtools-mcp@latest

      - name: Run Codex
        id: run_codex
        uses: openai/codex-action@v1
        with:
          openai-api-key: ${{ secrets.OPENAI_API_KEY }}
          codex-args: |
            --config mcp_servers={'devtools'={'command'='chrome-devtools-mcp','args'=['--headless=true','--isolated=true']}}
          prompt: |
            1. chrome-devtoolsを開始する
            2. `https://subsidy-search-app.vercel.app`にアクセスする
            3. 自律的にスクロールを行い、ページの内容を理解すること
            4. 入力やクリックを行い、テストを行うこと
            5. 常にコンソールエラーが出ていないか注視すること
            6. テストが完了したらユーザーにフィードバックをする
  create_issue:
    runs-on: ubuntu-latest
    needs: codex
    if: needs.codex.outputs.final_message != ''
    permissions:
      issues: write
      pull-requests: write
    steps:
      - name: Create Report Issue
        env:
          GH_TOKEN: ${{ github.token }}
          REPO: ${{ github.repository }}
          CODEX_FINAL_MESSAGE: ${{ needs.codex.outputs.final_message }}
        run: gh issue create --title "E2Eレポート" --body "$CODEX_FINAL_MESSAGE" --repo "$REPO"

参考

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?