This is an automated email from the ASF dual-hosted git repository.
klesh pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
The following commit(s) were added to refs/heads/main by this push:
new 8d821498c feat: update post deployment curl for webhook (#7481)
8d821498c is described below
commit 8d821498cffc39f62b629d5e268e7f087eecbafc
Author: 青湛 <[email protected]>
AuthorDate: Fri May 17 17:24:51 2024 +1200
feat: update post deployment curl for webhook (#7481)
---
.../plugins/register/webhook/components/create-dialog.tsx | 14 ++++++--------
.../plugins/register/webhook/components/view-dialog.tsx | 14 ++++++--------
2 files changed, 12 insertions(+), 16 deletions(-)
diff --git
a/config-ui/src/plugins/register/webhook/components/create-dialog.tsx
b/config-ui/src/plugins/register/webhook/components/create-dialog.tsx
index d293508f7..3f3c9ca58 100644
--- a/config-ui/src/plugins/register/webhook/components/create-dialog.tsx
+++ b/config-ui/src/plugins/register/webhook/components/create-dialog.tsx
@@ -86,14 +86,12 @@ export const CreateDialog = ({ open, onCancel,
onSubmitAfter }: Props) => {
}'`,
closeIssuesEndpoint: `curl ${prefix}${res.closeIssuesEndpoint} -X
'POST' -H 'Authorization: Bearer ${res.apiKey}'`,
postDeploymentsCurl: `curl
${prefix}${res.postPipelineDeployTaskEndpoint} -X 'POST' -H 'Authorization:
Bearer ${res.apiKey}' -d '{
- "deployment_commits":[
- {
- "commit_sha":"the sha of deployment commit1",
- "repo_url":"the repo URL of the deployment commit"
- }
- ],
- "start_time":"Optional, eg. 2020-01-01T12:00:00+00:00"
-}'`,
+ "pipeline_id": "Required. This will be the unique id of the
deployment",
+ "repo_url":"e.g. GitHub - apache/incubator-devlake: Apache DevLake
is an open-source dev data platform to ingest, ana",
+ "display_title":"optional-custom-deploy-display-title",
+ "commit_sha":"e.g. 015e3d3b480e417aede5a1293bd61de9b0fd051d",
+ "start_time":"Optional, e.g. 2020-01-01T12:00:00+00:00"
+ }'`,
apiKey: res.apiKey,
});
onSubmitAfter?.(res.id);
diff --git a/config-ui/src/plugins/register/webhook/components/view-dialog.tsx
b/config-ui/src/plugins/register/webhook/components/view-dialog.tsx
index bb44c7a39..d2f80a181 100644
--- a/config-ui/src/plugins/register/webhook/components/view-dialog.tsx
+++ b/config-ui/src/plugins/register/webhook/components/view-dialog.tsx
@@ -51,14 +51,12 @@ const transformURI = (prefix: string, webhook: IWebhook,
apiKey: string) => {
postDeploymentsCurl: `curl
${prefix}${webhook.postPipelineDeployTaskEndpoint} -X 'POST' -H 'Authorization:
Bearer ${
apiKey ?? '{API_KEY}'
}' -d '{
- "deployment_commits":[
- {
- "commit_sha":"the sha of deployment commit1",
- "repo_url":"the repo URL of the deployment commit"
- }
- ],
- "start_time":"Optional, eg. 2020-01-01T12:00:00+00:00"
- }'`,
+ "pipeline_id": "Required. This will be the unique id of the deployment",
+ "repo_url":"e.g. GitHub - apache/incubator-devlake: Apache DevLake is an
open-source dev data platform to ingest, ana",
+ "display_title":"optional-custom-deploy-display-title",
+ "commit_sha":"e.g. 015e3d3b480e417aede5a1293bd61de9b0fd051d",
+ "start_time":"Optional, e.g. 2020-01-01T12:00:00+00:00"
+ }'`,
};
};