fix(gitea TLS): 固定略過憑證驗證並改用 Gitea context
This commit is contained in:
+8
-38
@@ -2,34 +2,6 @@ name: 'AI Code Review'
|
||||
description: 'AI Code Review'
|
||||
author: 'Jeffery'
|
||||
inputs:
|
||||
# Gitea context
|
||||
gitea_token:
|
||||
description: 'Gitea API Token'
|
||||
required: true
|
||||
gitea_comment_token:
|
||||
description: 'Gitea API Token for posting comments only'
|
||||
required: false
|
||||
gitea_server_url:
|
||||
description: 'Gitea Server URL'
|
||||
required: false
|
||||
gitea_repository:
|
||||
description: 'Gitea Repository (owner/repo)'
|
||||
required: false
|
||||
gitea_skip_tls_verify:
|
||||
description: '跳過 Gitea SSL/TLS 憑證驗證(自簽憑證時使用)'
|
||||
required: false
|
||||
default: 'false'
|
||||
pr_number:
|
||||
description: 'Pull Request Number'
|
||||
required: false
|
||||
pr_head_sha:
|
||||
description: 'PR head commit SHA'
|
||||
required: false
|
||||
pr_head_branch:
|
||||
description: 'PR 來源分支'
|
||||
required: false
|
||||
|
||||
# OpenCode Server
|
||||
opencode_base_url:
|
||||
description: 'OpenCode server Base URL'
|
||||
required: false
|
||||
@@ -43,16 +15,14 @@ runs:
|
||||
using: 'docker'
|
||||
image: 'Dockerfile'
|
||||
env:
|
||||
# Gitea context(改為只從 inputs 取得)
|
||||
GITEA_TOKEN: ${{ inputs.gitea_token }}
|
||||
GITEA_COMMENT_TOKEN: ${{ inputs.gitea_comment_token }}
|
||||
GITEA_SERVER_URL: ${{ inputs.gitea_server_url || gitea.server_url }}
|
||||
GITEA_REPOSITORY: ${{ inputs.gitea_repository || gitea.repository }}
|
||||
GITEA_SKIP_TLS_VERIFY: ${{ inputs.gitea_skip_tls_verify }}
|
||||
PR_NUMBER: ${{ inputs.pr_number || gitea.event.pull_request.number }}
|
||||
PR_HEAD_SHA: ${{ inputs.pr_head_sha || gitea.event.pull_request.head.sha }}
|
||||
PR_HEAD_BRANCH: ${{ inputs.pr_head_branch || gitea.event.pull_request.head.ref }}
|
||||
# LLM
|
||||
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||
GITEA_REPOSITORY: ${{ gitea.repository }}
|
||||
GITEA_TOKEN: ${{ gitea.token }}
|
||||
GITEA_COMMENT_TOKEN: ${{ gitea.token }}
|
||||
PR_NUMBER: ${{ gitea.event.pull_request.number }}
|
||||
PR_HEAD_SHA: ${{ gitea.event.pull_request.head.sha }}
|
||||
PR_HEAD_BRANCH: ${{ gitea.event.pull_request.head.ref }}
|
||||
PR_BASE_BRANCH: ${{ gitea.event.pull_request.base.ref }}
|
||||
OPENCODE_BASE_URL: ${{ inputs.opencode_base_url }}
|
||||
OPENCODE_MODEL: ${{ inputs.opencode_model }}
|
||||
OPENCODE_PROVIDER: ${{ inputs.opencode_provider }}
|
||||
|
||||
Reference in New Issue
Block a user